Fix skipOffset with dynamic RegExpr
ClosedPublic

Authored by jpoelen on Sep 23 2019, 10:57 PM.

Details

Summary

The pattern used depends on the previous contexts so skipOffset cannot be computed with a dynamic regex.

BUG: 399388

Diff Detail

Repository
R216 Syntax Highlighting
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
jpoelen requested review of this revision.Sep 23 2019, 10:57 PM
jpoelen created this revision.
cullmann accepted this revision.Sep 24 2019, 7:42 AM

Seems reasonable, thanks
I think it would be nice to have a comment added to the

612 ​
613 /
613 ​ /

614 * no match
614 ​ * no match
615 */
615 ​ */
616 return MatchResult(offset, result.capturedStart());

part with reference to the issue.
Then please commit.

This revision is now accepted and ready to land.Sep 24 2019, 7:42 AM
jpoelen updated this revision to Diff 66788.Sep 24 2019, 9:33 PM
  • add a comment
cullmann accepted this revision.Sep 25 2019, 6:12 AM
This revision was automatically updated to reflect the committed changes.