> foreach @bigarray { > sub { > yield (push @array1, $_); > yield (push @array2, $_); > yield (push @array3, $_); > push @array4, $_; > }->(); > }; > > :-) As I've said before, Randal, you're a bad, bad man. Of course, the following *would* work as desired: my $unmerge = sub { yield (push @array1, $_); yield (push @array2, $_); yield (push @array3, $_); return (push @array4, $_); }; foreach @bigarray { $unmerge->(); } It's only drawback being that it's appalling. ;-) Damian
- Re: $a in @b Damien Neil
- Re: $a in @b Damian Conway
- Re: $a in @b John Porter
- Re: $a in @b Chaim Frenkel
- Re: $a in @b Damian Conway
- C<map> in RFC 31 David L. Nicol
- Re: C<map> in RFC 31 Damian Conway
- more yield tricks ((was Re: ... David L. Nicol
- Re: more yield tricks ((was... Damian Conway
- Re: more yield tricks ((was ... Randal L. Schwartz
- Re: $a in @b Damian Conway
- Re: $a in @b David L. Nicol
- Re: $a in @b Jarkko Hietaniemi
- Re: $a in @b Graham Barr
- RE: $a in @b Damian Conway
- RE: $a in @b Garrett Goebel
- RE: $a in @b Garrett Goebel
- Re: $a in @b John Porter
- Re: $a in @b Damian Conway
- Re: $a in @b John Porter
- Re: $a in @b David L. Nicol