[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Down with Upvalues
- From: Edgar Toernig <froese@...>
- Date: Fri, 31 Aug 2001 03:41:59 +0200
"John D. Ramsdell" wrote:
>
> On another subject, can we agree that Lua variables do not have nested
> scope?
He? Of course they have nested scope. Or how would you call this?
i="level0"
do
local i="level1"
while foo do
local i="level2"
if bar then
local i="level3"
function baz()
local i="level4"
print i -- level4
end
print i -- level3
else
print i -- level2
end
print i -- level2
end
print i -- level1
end
print i -- level0
Ciao, ET.