lua-users home
lua-l archive

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


2014-04-16 23:46 GMT+02:00 Sean Conner <sean@conman.org>:

> Fixing this in Lua would be a massive internal overhaul of how the
> compiler works, and most likely make Lua slower.  The reason locals are
> faster than table lookups is that locals are really VM registers, which
> also explains why locals can't be declared at runtime.

And why there can be no more than 200 of them per scope.

>> and varargs not being easier to store/handle

However, varargs and return lists are also registers.

> (there are things I would love to change about C, but I'm realistic
> enough to know that I have as much chance as Cnut stopping the
> waves).

If Cnut is a C hobbyist, a Lua enthusiast is a Brazil nut.