-
Notifications
You must be signed in to change notification settings - Fork 212
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
feat: Improve quote handling in lexer #3274
Conversation
Improvements described inline
Chumsky errors were actually decipherable once I got used to them! |
// Escape each inner quote depending on the outer quote | ||
assert_snapshot!(quoted_string(true).parse(r#""\"hello\"""#).unwrap(), @r###""hello""###); | ||
assert_snapshot!(quoted_string(true).parse(r#"'\'hello\''"#).unwrap(), @"'hello'"); |
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.
This was previously handled incorrectly, IIUC
for more information, see https://pre-commit.ci
@aljazerzen the gentlest of pings, no real rush |
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.
Much better and faster probably. And it handles arbitrary many opening quotes.
Improvements described inline