Skip to content

Fix forward progress detection for lookaround groups#866

Open
ekassos wants to merge 1 commit into
swiftlang:mainfrom
ekassos:lookaround-forward-progress-fix
Open

Fix forward progress detection for lookaround groups#866
ekassos wants to merge 1 commit into
swiftlang:mainfrom
ekassos:lookaround-forward-progress-fix

Conversation

@ekassos

@ekassos ekassos commented Jun 20, 2026

Copy link
Copy Markdown

When a quantified concatenation begins with a lookaround group, the forward progress checker fails to skip over the assertion's child subtree, leaving the analysis cursor misaligned and leading to false positives.

This change skips the lookaround's child subtree, matching the treatment added for nullable quantifications in #851.

Fixes #865.

When a quantified concatenation begins with a lookaround group, the forward
progress checker fails to skip over the assertion's child subtree, leaving the
analysis cursor misaligned and leading to false positives.

This change skips the lookaround's child subtree, matching the treatment added
for nullable quantifications in swiftlang#851.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

RegexBuilder infinite loop when nullable capture starts with NegativeLookahead

1 participant