summaryrefslogtreecommitdiff
path: root/perltest.pl
diff options
context:
space:
mode:
authorph10 <ph10@2f5784b3-3f2a-0410-8824-cb99058d5e15>2010-03-27 17:45:29 +0000
committerph10 <ph10@2f5784b3-3f2a-0410-8824-cb99058d5e15>2010-03-27 17:45:29 +0000
commit830417cb79946e957b855d50218d64d74562f47c (patch)
tree161e947d9b2552dfbb79ccc5b87674c8c785a983 /perltest.pl
parent156c5951245218524c2f59f97eb66a1e48a71eae (diff)
downloadpcre-830417cb79946e957b855d50218d64d74562f47c.tar.gz
Add support for *MARK and names for *PRUNE, *SKIP, *THEN.
git-svn-id: svn://vcs.exim.org/pcre/code/trunk@510 2f5784b3-3f2a-0410-8824-cb99058d5e15
Diffstat (limited to 'perltest.pl')
-rwxr-xr-xperltest.pl15
1 files changed, 10 insertions, 5 deletions
diff --git a/perltest.pl b/perltest.pl
index 1df863e..b73646b 100755
--- a/perltest.pl
+++ b/perltest.pl
@@ -85,15 +85,19 @@ for (;;)
# The private /+ modifier means "print $' afterwards".
- $showrest = ($pattern =~ s/\+(?=[a-z]*$)//);
+ $showrest = ($pattern =~ s/\+(?=[a-zA-Z]*$)//);
# Remove /8 from a UTF-8 pattern.
- $utf8 = $pattern =~ s/8(?=[a-z]*$)//;
+ $utf8 = $pattern =~ s/8(?=[a-zA-Z]*$)//;
# Remove /J from a pattern with duplicate names.
- $pattern =~ s/J(?=[a-z]*$)//;
+ $pattern =~ s/J(?=[a-zA-Z]*$)//;
+
+ # Remove /K from a pattern (asks pcretest to check MARK data) */
+
+ $pattern =~ s/K(?=[a-zA-Z]*$)//;
# Check that the pattern is valid
@@ -127,8 +131,9 @@ for (;;)
chomp;
printf $outfile "$_\n" if $infile ne "STDIN";
- s/\s+$//;
- s/^\s+//;
+ s/\s+$//; # Remove trailing space
+ s/^\s+//; # Remove leading space
+ s/\\Y//g; # Remove \Y (pcretest flag to set PCRE_NO_START_OPTIMIZE)
last if ($_ eq "");
$x = eval "\"$_\""; # To get escapes processed