lua-users home
lua-l archive

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

> On Wed, Nov 20, 2013 at 12:04 PM, Pierre Chapuis <>
> wrote:

> (An example of Moonscript implementing a lua-l request is the
> treatment of the colon operator, which is '\' in Moonscript (still
> feels like an escape to me, but colon was out for other reasons).
> That is, a\foo(arg) translates to a:foo(arg), but a\foo without args
> is an expression returning a partial application where the self is
> bound - useful for callbacks.)

Idiomatic Moonscript code (if that exists) is probably more
functional and "clever" than Lua. But I am not sure that this
is always a net win.

For instance, take this. Can you guess what this does?

Yes, this is clever. And error-prone:

I would almost always rather have slightly longer, boring but
straightforward Lua code.

Pierre Chapuis