diff options
Diffstat (limited to 't/pragma/warn/pp_hot')
-rw-r--r-- | t/pragma/warn/pp_hot | 29 |
1 files changed, 26 insertions, 3 deletions
diff --git a/t/pragma/warn/pp_hot b/t/pragma/warn/pp_hot index 6bd315148f..9a4b0a0708 100644 --- a/t/pragma/warn/pp_hot +++ b/t/pragma/warn/pp_hot @@ -36,11 +36,13 @@ glob failed (child exited with status %d%s) [Perl_do_readline] <<TODO Deep recursion on subroutine \"%s\" [Perl_sub_crush_depth] - sub fred { fred() if $a++ < 200} fred() + sub fred { fred() if $a++ < 200} fred() Deep recursion on anonymous subroutine [Perl_sub_crush_depth] - $a = sub { &$a if $a++ < 200} &$a + $a = sub { &$a if $a++ < 200} &$a + Possible Y2K bug: about to append an integer to '19' [pp_concat] + $x = "19$yy\n"; __END__ # pp_hot.c [pp_print] @@ -189,4 +191,25 @@ $b = sub &$b ; EXPECT - +######## +# pp_hot.c [pp_concat] +use warnings 'misc'; +use Config; +BEGIN { + unless ($Config{ccflags} =~ /Y2KWARN/) { + print "SKIPPED\n# perl not built with -DPERL_Y2KWARN"; + exit 0; + } +} +my $x; +my $yy = 78; +$x = "19$yy\n"; +$x = "19" . $yy . "\n"; +$x = "319$yy\n"; +$x = "319" . $yy . "\n"; +no warnings 'misc'; +$x = "19$yy\n"; +$x = "19" . $yy . "\n"; +EXPECT +Possible Y2K bug: about to append an integer to '19' at - line 12. +Possible Y2K bug: about to append an integer to '19' at - line 13. |