diff options
author | Karl Williamson <public@khwilliamson.com> | 2012-07-06 11:31:11 -0600 |
---|---|---|
committer | Karl Williamson <public@khwilliamson.com> | 2012-07-24 21:13:45 -0600 |
commit | 44f5ace3a1ccc47acfcf84761428d69cc8c7792d (patch) | |
tree | 7019876736fd5a8e827eea6473fcc485b1dcb5f9 /regen/regcomp.pl | |
parent | 5a279aa01b85454d24e44898e581820d24e712b3 (diff) | |
download | perl-44f5ace3a1ccc47acfcf84761428d69cc8c7792d.tar.gz |
regen/regcomp.pl: Allow ';' in comments
If a comment contained a semi-colon, the regular expression's greedy
quantifier would think the portion of the comment before it was part of
the data to be processed
Diffstat (limited to 'regen/regcomp.pl')
-rw-r--r-- | regen/regcomp.pl | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/regen/regcomp.pl b/regen/regcomp.pl index 69643ca5b8..eef553311b 100644 --- a/regen/regcomp.pl +++ b/regen/regcomp.pl @@ -34,7 +34,7 @@ while (<DESC>) { next; } unless ($lastregop) { - ($name[$ind], $desc, $rest[$ind]) = /^(\S+)\s+([^\t]+)\s*;\s*(.*)/; + ($name[$ind], $desc, $rest[$ind]) = /^(\S+)\s+([^\t]+?)\s*;\s*(.*)/; ($type[$ind], $code[$ind], $args[$ind], $flags[$ind], $longj[$ind]) = split /[,\s]\s*/, $desc; ++$ind; |