lua-users home
lua-l archive

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

From: "Ben Sunshine-Hill" <>
There isn't necessarily any context, because blocks aren't always
Introduced by if, while, etc. Take the code { a = 1 }. Table
constructor or block?

If the statement terminator was mandatory, then it would clearly be a block because it's at the start of the statement. But really, I was not asking about freestanding blocks, but about if <condition> then <statements> end being sugared as if <condition> { statements } (same for while, for, function, etc). I believe this does have quite a context right?

To be specific again, I'm not talking about changing the base language (flamewars et al). Just asking about mod experience and possibilities for a specific use I'm gonna need.