On Sun, 27 Jun 2004, Luke Palmer wrote: > Alexey Trofimenko writes: > > AFAIR, I've seen in some Apocalypse that lexical scope boundaries will be > > the same as boundaries of block, in which lexical variable was defined. > > Yep. Except in the case of routine parameters, but that's nothing new.
(This may be a bit tangential, but it still concerns scope...) I am reminded of a strange case I came across in perl5, and I wondered how perl6 would behave for the following: $b = 'a'; my $b ='b' , print "$b\n"; print "$b\n"; In perl5, this prints: a b Which seems to show that the "my $b" doesn't actually come into scope until the end of the statement in which it is defined. Is that correct? and what will perl6 do? I know an obvious answer is "don't do that", which is what I had to (not) do, but this is a greatly simplified version of some generated code. ~ John Williams