mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-02-15 11:35:42 -06:00
When creating string literal for property access, unescape the identifier text
Fixes #12562
This commit is contained in:
parent
ea1f03915b
commit
7bb8331124
@ -1905,7 +1905,7 @@ namespace ts {
|
||||
: (<ComputedPropertyName>name).expression;
|
||||
}
|
||||
else if (isIdentifier(name)) {
|
||||
return createLiteral(name.text);
|
||||
return createLiteral(unescapeIdentifier(name.text));
|
||||
}
|
||||
else {
|
||||
return getSynthesizedClone(name);
|
||||
|
||||
@ -34,4 +34,4 @@ var A = (function () {
|
||||
}());
|
||||
__decorate([
|
||||
dec()
|
||||
], A.prototype, "___foo");
|
||||
], A.prototype, "__foo");
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user