lua-users home
lua-l archive

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


On Sun, Nov 17, 2013 at 11:16 AM, Dirk Laurie <dirk.laurie@gmail.com> wrote:
> What we should rather be looking for, is something with much
> wider application that happens to be a convenient way of also
> implementing this feature.

Now that makes sense!

It has to happen at the language level, because of local slot
allocation being compile-time.

Something like 'local insert, concat from table' is of course also
useful in local function contexts.  There the scope isn't so large so
the renaming thing is no longer so crucial (and there are other
technical advantages, such as not using too using too many file-level
local slots, and true locals being a little faster than upvalues)

We all have _run-time_ tricks (pl has utils.import etc) but they are
going to be slower and make it harder to understand what's happening
in a program - mostly for 'scripting' as opposed to 'programming'.