[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: detecting undefined variables--a new mixed approach
- From: Luiz Henrique de Figueiredo <lhf@...>
- Date: Tue, 25 Mar 2008 10:29:20 -0300
> So, as an example, a function might contain lines
> label "loop_reentry"
> goto "loop_reentry"
> Then after loading, it would be possible to run through the opcodes,
> identify the getglobal/loadk/call of these label and goto constructs,
> and replace them with "move r0 := r0" and "jump offset" respectively.
I did exactly that once. It works fine and is easy to implement. Not that
we want to add goto to Lua... (which is why I never posted the code).