Skip to content

Commit

Permalink
Fix before handling in NFA generation.
Browse files Browse the repository at this point in the history
  • Loading branch information
jnthn committed Jun 6, 2012
1 parent 2dc71bc commit 0920483
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/QRegex/NFA.nqp
Expand Up @@ -120,7 +120,9 @@ class QRegex::NFA {
method subrule($node, $from, $to) {
my $subtype := $node.subtype;
if $node.name eq 'before' && !$node.negate {
self.regex_nfa($node[0][1]<orig_qast>, $from, 0);
my $end := self.addstate();
self.regex_nfa($node[0][1]<orig_qast>, $from, $end);
self.fate($node, $end, $to);
}
elsif $subtype ne 'zerowidth' &&
($node.name eq 'alpha' ||
Expand Down

0 comments on commit 0920483

Please sign in to comment.