lua-users home
lua-l archive

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


On Tue, Apr 8, 2014 at 3:31 PM, Coroutines <coroutines@gmail.com> wrote:
> Your last statement frustrates me.  I could see "new syntax" being scary,
> but another languages' semantics?  Are you kidding?  How is it another
> language to essentially pull in references in batch from one table to
> another?

It ain't crap, it's just how Lua resolves symbol references; either
they are in the environment or they are locals.  'local import foo' is
impossible with Lua semantics, because each new local slot has to be
allocated at compile time, and we don't _know_ what foo contains.

> Some of you act like you've never seen a 20-30 line list of local
> declarations that you hope aren't full of typos.

We do test our programs, you know ;)

Look, it _can_ be tedious to type (which is why I like editor-time
macro expansion) and it _can_ be tedious to read (in which case use a
macro preprocessor).

I'm really not adverse to 'import x,y,z from foo' syntax sugar,
actually. I just don't think it's something that's sufficiently
important to make the cut.