You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The optimization we employ in RegexNode.FinalOptimize to insert an UpdateBumpalong node after a starting loop does so for unbounded {One/Notone/Set}loop{atomic} nodes, but not for {One/Notone/Set}lazy nodes.
It should be applicable for lazy loops as well, as if the match ends up failing, we will have explored the same range, just effectively in the opposite direction. One thing that may need more thought is if we need to special-case not applying this for atomic lazy loops, which will always only check for the minimum bound.
(This code, and other code in RegexNode, can also be cleaned up nicely now that we have improved C# pattern matching support.)
The text was updated successfully, but these errors were encountered:
Tagging subscribers to this area: @dotnet/area-system-text-regularexpressions
See info in area-owners.md if you want to be subscribed.
Issue Details
The optimization we employ in RegexNode.FinalOptimize to insert an UpdateBumpalong node after a starting loop does so for unbounded {One/Notone/Set}loop{atomic} nodes, but not for {One/Notone/Set}lazy nodes.
It should be applicable for lazy loops as well, as if the match ends up failing, we will have explored the same range, just effectively in the opposite direction. One thing that may need more thought is if we need to special-case not applying this for atomic lazy loops, which will always only check for the minimum bound.
The optimization we employ in RegexNode.FinalOptimize to insert an UpdateBumpalong node after a starting loop does so for unbounded {One/Notone/Set}loop{atomic} nodes, but not for {One/Notone/Set}lazy nodes.
runtime/src/libraries/System.Text.RegularExpressions/src/System/Text/RegularExpressions/RegexNode.cs
Lines 396 to 401 in 12a8819
It should be applicable for lazy loops as well, as if the match ends up failing, we will have explored the same range, just effectively in the opposite direction. One thing that may need more thought is if we need to special-case not applying this for atomic lazy loops, which will always only check for the minimum bound.
(This code, and other code in RegexNode, can also be cleaned up nicely now that we have improved C# pattern matching support.)
The text was updated successfully, but these errors were encountered: