Skip to content

Commit

Permalink
No funny business in precomped string strands
Browse files Browse the repository at this point in the history
  • Loading branch information
zoffixznet committed Oct 11, 2017
1 parent 807ed81 commit 28481ce
Showing 1 changed file with 16 additions and 1 deletion.
17 changes: 16 additions & 1 deletion S10-packages/precompilation.t
Expand Up @@ -3,7 +3,7 @@ use lib 't/spec/packages';
use Test;
use Test::Util;

plan 51;
plan 53;

my @*MODULES; # needed for calling CompUnit::Repository::need directly
my $precomp-ext := $*VM.precomp-ext;
Expand Down Expand Up @@ -295,3 +295,18 @@ subtest 'precompiled module constants get updated on change' => {
{:out("pass\n"), :err('')},
"modified content has updated";
}
# RT#131924
with make-temp-dir() -> $dir {
$dir.add('Simple131924.pm6').spurt:
unit class Simple131924; sub buggy-str is export { “: {‘’}\n\r” ~ “\n\r” }
;
for ^2 { # do two runs: 1 x without pre-existing precomp + 1 x with
is_run 'use lib \qq[$dir.absolute().perl()]; use Simple131924; '
~ 'print buggy-str() eq “: \n\r\n\r”',
{:out<True>, :err(''), :0status},
'no funny business with precompiled string strands (\qq[$_])';
}
}

0 comments on commit 28481ce

Please sign in to comment.