Skip to content

Commit 5523be6

Browse files
committed
Make sure we terminate LTM on imperative pastnode cases.
1 parent f5ad380 commit 5523be6

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/QRegex/NFA.nqp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,9 @@ class QRegex::NFA {
161161
}
162162

163163
method pastnode($node, $from, $to) {
164-
self.addedge($from, $to, $EDGE_EPSILON, 0);
164+
$node.subtype eq 'zerowidth' || $node.subtype eq 'declarative' ??
165+
self.addedge($from, $to, $EDGE_EPSILON, 0) !!
166+
self.fate($node, $from, $to);
165167
}
166168

167169
method subcapture($node, $from, $to) {

0 commit comments

Comments
 (0)