lua-users home
lua-l archive

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


> If 5.3 has new keywords, then global is just one
> more parser issue to trap, so it's not a big deal to
> trap this one too.

5.3.0.work2 has no new keywords.

Adding a new keyword to Lua is not merely an issue about
implementation details like trapping things in the parser.
It's about backward compatibility (how many existing
correct Lua programs use the name `global`?), describing
it in the manual,  the keyword footprint of Lua ("fewer keywords
than the original Pascal" has a nice ring to it).

The last new keyword added was "goto". Many other languages
have it, so people tended to avoid it as a name. It solves the
problem of the missing "continue". Even so, many people felt
we could have done without it and still avoid using it.

Introducing a new keyword is like a heart transplant. It's the
last resort when less invasive surgery fails.