lua-users home
lua-l archive

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


>>>>> "Patrick" == Patrick Donnelly <batrick@batbytes.com> writes:

 >> Why an error must be raised if a value doesn't have the metamethod?

 Patrick> I do wonder why not allow functions to be assigned and called
 Patrick> when the local goes out of scope.

This feature existed when *toclose was first added, and was then
explicitly removed. One problem is that it lets lua code catch errors in
ways that a sandbox can't control.

See https://github.com/lua/lua/commit/4ace93ca6502dd1da38d5c06fa099d229e791ba8

-- 
Andrew.