Re: How to change the function behavior at run-time in luav5.1.4
[
Date Prev][
Date Next][
Thread Prev][
Thread Next]
[
Date Index]
[
Thread Index]
- Subject: Re: How to change the function behavior at run-time in luav5.1.4
- From: zhqqmao <zhqqmao@...>
- Date: 2010年1月28日 16:13:17 +0000 (UTC)
> There isn't a very good way to do what you're describing directly.
> One thing you can do is create mutable proxy functions and have the
> callers only see those. If all the functions you describe are in a
> table you control, you can use a metatable on that table to make the
> indirection functions automatically.
Thank you for your reply, it really is a good idea
But I am a bit curious about is why the changes ldc-> lp = valc-> lp will lead
to memory disorders, as far as I know proto and the closure is separate from
recycling.