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

[CS2] Fix #4589: Don’t unnecessarily escape quotes in template literals #4660

Merged

Conversation

GeoffreyBooth
Copy link
Collaborator

@GeoffreyBooth GeoffreyBooth commented Aug 24, 2017

Fixes #4589. "a\"#{1}\"b" now becomes `a"${1}"b`, not `a\"${1}\"b`. @greghuc @xixixao.

Yes, this PR changes only four characters.

…es, so that quotation marks are not unnecessarily escaped in backtick-delimited strings/template literals
@GeoffreyBooth GeoffreyBooth changed the title Fix #4589: Don’t unnecessarily escape quotes in template literals [CS2] Fix #4589: Don’t unnecessarily escape quotes in template literals Aug 24, 2017
@greghuc
Copy link
Contributor

greghuc commented Aug 24, 2017

If all the tests pass, then LGTM. Previous bugs possibly affected by this: #4380.

StringWithInterpolations.compileNode() looks way more complicated than last time I looked at it!

@GeoffreyBooth
Copy link
Collaborator Author

StringWithInterpolations.compileNode() looks way more complicated than last time I looked at it!

Yes, largely thanks to @xixixao 😉 So @xixixao, does this change look okay to you?

@GeoffreyBooth GeoffreyBooth merged commit 9ff82fe into jashkenas:2 Aug 27, 2017
@GeoffreyBooth GeoffreyBooth deleted the escaped-quotes-in-template-literals branch August 27, 2017 22:16
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.

2 participants