Skip to content

Escape apparent substitution in synthesized NoSubstitutionTemplateLiterals #32580

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

Merged
merged 2 commits into from
Aug 5, 2019

Conversation

andrewbranch
Copy link
Member

Fixes #32515

The issue was in re-printing a NoSubstitutionTemplateLiteral with an escaped would-be substitution in it: `this is \${not} a substitution`. The node text simply becomes this is ${not} a substitution, and when we were re-writing that to a new node, we were printing that text as-is, when we needed to insert a backslash before the ${.

@andrewbranch andrewbranch requested a review from rbuckton July 26, 2019 19:19
@andrewbranch andrewbranch changed the title Bug/32515 Escape apparent substitution in synthesized NoSubstitutionTemplateLiterals Jul 26, 2019
@andrewbranch andrewbranch merged commit c1e0db7 into microsoft:master Aug 5, 2019
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.

Debug Failure. False expression: Token end is child end
2 participants