Subject: | heredoc misparsed as <diamond> |
$ cat try.pl
#!/usr/bin/env perl
use strict;
use warnings;
use PPR;
my $code = <<'_EOT_';
<<A
Show quoted text
>> iffy
A
_EOT_
$code =~ m{ \A (?&PerlDocument) \z $PPR::GRAMMAR }x
or warn "Not valid Perl according to PPR";
print eval $code;
die $@ if $@;
__END__
$ perl try.pl
Not valid Perl according to PPR at try.pl line 13.
Show quoted text>> iffy