[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: RE: Making vars local by default (completely off topic)
- From: Luiz Henrique de Figueiredo <lhf@...>
- Date: Wed, 23 May 2001 21:05:28 -0300 (EST)
>I have always suspected that there was a mechanism for doing this that I was
>missing. How does it work?
The construct
xyz { a=10, b=20 }
is the same as
xyz ({ a=10, b=20 })
that is, the *function* xyz is called with the given table.
This syntactical sugar is the basis of the powerful data description facilities
of Lua. Such statements look declarative but are procedural.
--lhf