Skip to content
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

Fix multiline dollar escape #102

Merged
merged 1 commit into from
Jul 23, 2022
Merged

Conversation

darichey
Copy link
Contributor

Summary & Motivation

Previously, if the tokenizer encountered the sequence of characters ''\$, next_string would consume the first 3 and then loop back around and see the $ next, which it treated as the start of an interpolation.

With this change, it will instead always immediately consume the next character after ''\ before looping back. This is correct, because ''\x is a valid escape sequence for any x.

Further context

Fixes #100

@oberblastmeister
Copy link
Contributor

This looks good, thanks for the fix!

@oberblastmeister oberblastmeister merged commit aad261b into nix-community:master Jul 23, 2022
oberblastmeister added a commit to oberblastmeister/rnix-parser that referenced this pull request Jul 24, 2022
@oberblastmeister oberblastmeister mentioned this pull request Jul 24, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Multiline dollar escape sequence not handled properly
2 participants