lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

Luiz Henrique de Figueiredo wrote:

Can we submit proposed patches here?

Sure, it'll help others. Thanks.


Lua 5.2 Work 2 is now compiling clean on bare metal for the LEGO

I had one user that had an issue with 5.1.4 that thought it would
be a good idea to do something like this:

co = coroutine.create( function( n ) )
       while n>0 do
         n = n-1
     end )

The main loop basically called the function with some arbitrary
value for n and then control was passed back and forth to the coroutine
until n was 0.

Simplest thing that could possibly work - but it broke. And I ended
up doing a ton of research on setjmp() and friends and finally concluded
that the heap was exhausted and I needed emergency garbage collection.

SO then I jumped ahead and got the Work 2 code, spent a grand total
of about 2 hours getting things plugged into my environment and
fixing compiler/linker errors, and now I have this case working
with no problems at all!!!

Great job, everyone! Especially for the emergency garbage collection.

Code size is a bit bigger than the old Lua, but not too horribly

I'll post more notes as I learn more about this build. So far, so good.