-
Notifications
You must be signed in to change notification settings - Fork 13k
Fix incorrectly emitting underscore of imported property #6194
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
Conversation
src/compiler/utilities.ts
Outdated
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.
I liked the short form better, although putting it in its own function is nice.
I don't see the tests yet. |
…peScript into fix4867_transpiling
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.
add a comment why do we need to unescape the text here
src/compiler/utilities.ts
Outdated
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.
prefixedWithUnderscores
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.
Below we use identifier.length >= 3
so make these align.
@DanielRosenwasser @sandersn @vladima any comment? |
src/compiler/utilities.ts
Outdated
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.
What is the purpose of changing the comparison from identifier.length >= 2
to identifier.length >= 3
? With this change, we won't escape __a
to ___a
. Is that expected?
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.
Thanks @rbuckton for pointing this out. we don't really need the check any more since we will unescape anyway
👍 |
:+!: |
Fix incorrectly emitting underscore of imported property
Fix #4867