Skip to content

Commit 3bc17b6

Browse files
committed
Add tests for a weird segv issue
Resolves rakudo/rakudo#2486.
1 parent 73eb90d commit 3bc17b6

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

integration/weird-errors.t

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ use Test;
33
use lib $?FILE.IO.parent(2).add("packages/Test-Helpers");
44
use Test::Util;
55

6-
plan 32;
6+
plan 33;
77

88
# this used to segfault in rakudo
99
is_run(
@@ -248,3 +248,7 @@ is (^1000 .grep: -> $n {([+] ^$n .grep: -> $m {$m and $n %% $m}) == $n }), (0, 6
248248
# https://irclog.perlgeek.de/perl6/2017-04-18#i_14443061
249249
is_run class Foo {}; $ = new Foo:, {:out(''), :err(''), :0status },
250250
'new Foo: calling form does not produce unwanted output';
251+
252+
# R#2486
253+
is_run sub f1 { hash a=>1 }; f1 for ^100000, {:out(''), :err(''), :0status },
254+
'no segfault when using `hash` in a function';

0 commit comments

Comments
 (0)