[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Fragile Recursion?
- From: Miles Bader <miles@...>
- Date: Wed, 11 Apr 2012 05:46:40 +0900
GrayFace <firstname.lastname@example.org> writes:
> do...end has nothing to do with a closure. A closure is an 'instance'
> of function, thus it's created once in any of your examples. In the
> first case it doesn't contain any upvalues in Lua 5.1, while it does
> in 5.2.
It contains an upvalue in both 5.1 and 5.2: the recursive reference
to the local (in the file) definition of "fact".
Genealogy, n. An account of one's descent from an ancestor who did not
particularly care to trace his own.