lua-users home
lua-l archive

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

> local table = { }
> second = table

> Does a change on table will be propagated to second ?

"second" is a reference to "table", so no copy is made and yes changing
"second" will change "table"

>local table = { }
>function table.test ()
>  print("Mooh !")
>Does it creates a function test inside the table 'table' ?

Yes ( quick answer :).  "function table.test()" creates a new key named
"test".  The value associated to the key is your function.

Yann Com-Nougué