-
Notifications
You must be signed in to change notification settings - Fork 233
Tokenizers: don't throw, report errors as a new Invalid
token
#3835
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Invalid
token
52c6a88
to
644179d
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for working on this! Should be super useful!
case TRUE => Token.KwTrue(input, dialect, curr.offset) | ||
case FALSE => Token.KwFalse(input, dialect, curr.offset) | ||
case NULL => Token.KwNull(input, dialect, curr.offset) | ||
|
||
case INTERPOLATIONID => Token.Interpolation | ||
.Id(input, dialect, curr.offset, curr.endOffset, curr.strVal) | ||
case XMLLIT => getXmlPart(curr) | ||
case XMLLITEND => unreachable | ||
// case XMLLITEND => unreachable |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
// case XMLLITEND => unreachable |
and also other below?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do you mean to remove the lines completely? i kept them to indicate that these particular tokens should not be obtained via this method, and it's not an oversight they are not here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we just add a comment for all those at the end? It's fine either way
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
Addresses proposal mentioned in #3813.