Revision: 1497
http://vcs.pcre.org/viewvc?view=rev&revision=1497
Author: ph10
Date: 2014-08-08 15:50:26 +0100 (Fri, 08 Aug 2014)
Log Message:
-----------
Tidy Perl compatibility test script.
Modified Paths:
--------------
code/trunk/perltest.pl
code/trunk/testdata/testinput1
code/trunk/testdata/testoutput1
Modified: code/trunk/perltest.pl
===================================================================
--- code/trunk/perltest.pl 2014-07-18 08:24:35 UTC (rev 1496)
+++ code/trunk/perltest.pl 2014-08-08 14:50:26 UTC (rev 1497)
@@ -80,8 +80,8 @@
$pattern .= $_;
}
- chomp($pattern);
- $pattern =~ s/\s+$//;
+ chomp($pattern);
+ $pattern =~ s/\s+$//;
# The private /+ modifier means "print $' afterwards".
@@ -121,6 +121,14 @@
if ($@)
{
printf $outfile "Error: $@";
+ if ($infile != "STDIN")
+ {
+ for (;;)
+ {
+ last if ! ($_ = <$infile>);
+ last if $_ =~ /^\s*$/;
+ }
+ }
next NEXT_RE;
}
Modified: code/trunk/testdata/testinput1
===================================================================
--- code/trunk/testdata/testinput1 2014-07-18 08:24:35 UTC (rev 1496)
+++ code/trunk/testdata/testinput1 2014-08-08 14:50:26 UTC (rev 1497)
@@ -111,7 +111,7 @@
bababbc
babababc
-/^\ca\cA\c[\c{\c:/
+/^\ca\cA\c[;\c:/
\x01\x01\e;z
/^[ab\]cde]/
Modified: code/trunk/testdata/testoutput1
===================================================================
--- code/trunk/testdata/testoutput1 2014-07-18 08:24:35 UTC (rev 1496)
+++ code/trunk/testdata/testoutput1 2014-08-08 14:50:26 UTC (rev 1497)
@@ -223,7 +223,7 @@
babababc
No match
-/^\ca\cA\c[\c{\c:/
+/^\ca\cA\c[;\c:/
\x01\x01\e;z
0: \x01\x01\x1b;z