blob: e74644d3fbde3c450a097699fc57285a9f9bb87a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
#!./perl
# Parser tests that want test.pl, eg to use runperl() for tests to show
# reads through invalid pointers.
# Note that this should still be runnable under miniperl.
BEGIN {
@INC = qw(. ../lib );
chdir 't' if -d 't';
}
require './test.pl';
plan(1);
# [perl #130814] can reallocate lineptr while looking ahead for
# "Missing $ on loop variable" diagnostic.
my $result = fresh_perl(
" foreach m0\n\$" . ("0" x 0x2000),
{ stderr => 1 },
);
is($result . "\n", <<EXPECT);
syntax error at - line 3, near "foreach m0
"
Identifier too long at - line 3.
EXPECT
__END__
# ex: set ts=8 sts=4 sw=4 et:
|