Compile lookaround regex to avoid compiling each time we want to use it

master
Aadhavan Srinivasan 4 weeks ago
parent 6208f32710
commit 34e9aedbd6

@ -469,6 +469,8 @@ func thompson(re []postfixNode) *State {
state.assert = NLB state.assert = NLB
} }
} }
tmpRe := shuntingYard(state.lookaroundRegex)
state.lookaroundNFA = thompson(tmpRe)
} }
} }

Loading…
Cancel
Save