Permalink
Browse files

RT #68298, $_ in block makes it not a hash

  • Loading branch information...
1 parent e225c9d commit 639a7664158925dd2326b15d1acc9ec906703007 @moritz moritz committed Dec 29, 2012
Showing with 4 additions and 1 deletion.
  1. +4 −1 S06-other/anon-hashes-vs-blocks.t
@@ -4,7 +4,7 @@ use Test;
# L<S06/Anonymous hashes vs blocks>
-plan 17;
+plan 18;
my $hash = {
'1' => { '2' => 3, '4' => 5 },
@@ -57,6 +57,9 @@ ok $bar ~~ Hash, '%foo in a block causes hash composing';
is %hash<1>, 'b', 'state variable declaration certainly makes it a block (2)';
}
+# RT #68298
+is (map { $_ => $_ * $_ }, 1..3).hash<2>, 4, 'block with $_ is not a hash';
+
done;
# vim: ft=perl6

0 comments on commit 639a766

Please sign in to comment.