lua-users home
lua-l archive

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




On Sep 9, 2021, at 12:27 AM, Philippe Verdy <verdyp@gmail.com> wrote:


Sure it does .. Lua allows semi-colon as an alternate to comma in table constructors. From the 5.3 reference manual:

tableconstructor ::= ‘{’ [fieldlist] ‘}’
	fieldlist ::= field {fieldsep field} [fieldsep]
	field ::= ‘[’ exp ‘]’ ‘=’ exp | Name ‘=’ exp | exp
	fieldsep ::= ‘,’ | ‘;


Note that a ‘fieldsep’ is comma or semi-colon.

-Tim