Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Question about scoping, .local and IMCC

1 view
Skip to first unread message

Clinton Pierce

unread,
Jun 27, 2003, 3:01:04 PM6/27/03
to perl6-i...@perl.org
After a quick reading of this, I'd have expected the value of "f" at the indicated point to be 1, but instead it's 2.

.local int f
.sub _main
.local int x
.sub _foo1
f=1
x=2
call _foo2
end
.end
.sub _foo2
call _another1
ret
.end
.end
.sub _another
.sub _another1
call _another2
ret
.end
.sub _another2
print "f is 1: "
print f
print "\n"
ret
.end
.end

Have I completely misunderstood something about .local?

0 new messages