lua-users home
lua-l archive

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


Why would it be desired to have a new anonymous function created for
each call?

function a()
	return function () end
end

print(a())
print(a())

> a() is referring to the anonymous function "function return b() end"
which
> is different to both a and b