Prevent lexer from skipping characters #1837
jonestristand
started this conversation in
General
Replies: 2 comments
-
Relevant code here: It would be very, very nice to be able to disable this sort of resync recovery if it is not desired... |
Beta Was this translation helpful? Give feedback.
0 replies
-
This may be possible as the logic is outside the main lexer "hotspot", but why do you need the feature? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
It appears that if the lexer can't get a match at the current index position on any token, it will go to the next index on the input string and attempt to match a token there, disregarding the skipped character. Is there any way to prevent this behaviour? e.g. if no lexing token matches at the current index, it should fail?
Beta Was this translation helpful? Give feedback.
All reactions