lua-users home
lua-l archive

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


On Wed, Apr 9, 2014 at 8:20 AM, steve donovan <steve.j.donovan@gmail.com> wrote:
> On Wed, Apr 9, 2014 at 5:14 PM, Coroutines <coroutines@gmail.com> wrote:
>> On the other hand if it winds up just being used for local
>> declarations at the head of files then performance isn't a concern and
>> it could be written in pure Lua just fine.
>
> Yep, like the slots/from hack - you really do not need that kind of
> magic in a frequently called function!

If `from()' were added I'd want it done in C and managed by upstream
so it can be used in more than just the head of a script.

-- BUT now I am more in favor of adding both forms of `in' beyond the
forloop-in:

local a, b, c in some_table
local a, b, c = x, y, z in some_table

I thought it would be confusing but I really like it.