3.3.3 – Assignment
Lua allows multiple assignments. Therefore, the syntax for assignment defines a list of variables on the left side and a list of expressions on the right side. The elements in both lists are separated by commas:
stat ::= varlist ‘=’ explist
varlist ::= var {‘,’ var}
explist ::= exp {‘,’ exp}
Expressions are discussed in §3.4.
Before the assignment, the list of values is adjusted to the length of the list of variables. If there are more values than needed, the excess valu