-
Notifications
You must be signed in to change notification settings - Fork 46
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
Lexer is panicking with some weird unicode chars #318
Closed
Labels
bug
Something isn't working
Comments
It panics because one of the (line terminator) characters in that particular string doesn't get added to the Error data, so we end up with an off by one error, which means we can't slice the original input string properly. As a quick workaround, you may wish to put this string into a raw string: |
lrlna
added a commit
that referenced
this issue
Sep 30, 2022
…tors We were missing adding a line terminator character to the errors created by the lexer in case of a unterminated string. This showed up incidentally while dealing with unicode and the fact that it's of a different byte length than most other characters. fixes #318
lrlna
added a commit
that referenced
this issue
Sep 30, 2022
…tors (#320) We were missing adding a line terminator character to the errors created by the lexer in case of a unterminated string. This showed up incidentally while dealing with unicode and the fact that it's of a different byte length than most other characters. fixes #318 Co-authored-by: Irina Shestak <[email protected]>
SimonSapin
pushed a commit
to apollographql/router
that referenced
this issue
Sep 30, 2022
…ues (#1921) fixes apollographql/apollo-rs#318 reported by @benjamn.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Here is a test to reproduce:
it will panic because it doesn't respect char boundary here
The text was updated successfully, but these errors were encountered: