Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
tests for RT #78026, RT #77302, gather/take value decontainerization
  • Loading branch information
moritz committed Oct 13, 2011
1 parent 1de96d9 commit 7b2fd5a
Showing 1 changed file with 18 additions and 1 deletion.
19 changes: 18 additions & 1 deletion S04-statements/gather.t
Expand Up @@ -2,7 +2,7 @@ use v6;

use Test;

plan 18;
plan 20;


# L<S04/The C<gather> statement prefix/>
Expand Down Expand Up @@ -171,5 +171,22 @@ plan 18;

}

# RT #78026, RT #77302
{
sub foo {
my @a = (1,2,3,4,5);
gather {
my $val ;
while @a {
$val = @a.shift();
take $val;
}
}
};
is foo().join, '12345', 'decontainerization happens (1)';
is (<a b c d e> Zxx 0,1,0,1,0).Str, 'b d',
'decontainerization happens (2)';
}


# vim: ft=perl6

0 comments on commit 7b2fd5a

Please sign in to comment.