On Sat, Jul 12, 2008 at 08:50:44AM -0700, chromatic wrote: > On Saturday 12 July 2008 08:06:33 Patrick R. Michaud wrote: > > > Short answer: cloning is what will enable the following to work: > > > > for 1..10 -> $x { > > sub foo() { say $x; } > > push(@foos, &foo); > > } > > Is that really valid Perl 6 code? I can see "my sub foo" working there, but > rebinding lexicals for global symbols goes against a decade of Perl 5 for me.
I don't know if it's valid or not. Pm