lua-users home
lua-l archive

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


Roberto wrote:
> That is similar to what we are thinking. A global keyword to declare
global
> variables, and a mode that demand explicit declaration of all variables
> that get *assigned* (not used; otherwise we sould have to declare every
> global function that we call... Or should we?). (Maybe the "global"
> declaration itself may work also as a switch for strict declaration mode.)

So how do things work at the global scope?  Unless there is some good reason
to make the global keyword required there, it would be nice not to.  Then
"normal" global function and data definitions will not be affected.

It seems that this globals issue is tied with whatever the module system
becomes.  It's hard to decide about one without the other.