TypeScript Version: 3.8.0-dev.20191228
Search Terms:
Code
class C{
#prop = 1;
method() {
const { #prop/*1*/: prop } = this;
({ #prop/*2*/: this.#prop } = this);
}
}
Expected behavior:
Error at /*1*/ and /*2*/ since this syntax is not (yet) allowed. tc39/proposal-class-fields#4
Thanks to Titian Cernicova-Dragomir (@dragomirtitian) for pointing this out.
Actual behavior:
No error.
Playground Link: https://www.typescriptlang.org/play/?ts=3.8.0-dev.20191228&ssl=7&ssc=2&pln=1&pc=1#code/MYGwhgzhAEDCDeAoaLoGIAOAnA9h6AvNAIwDcyqAtgKYAuAFjgCYAUAlNEqt9MDgHYRandNjwAuaGPwBfQtAYBLCOR6oW8UbgySlEAHSZt0OUT1tVqGYhlA
Related Issues: #35934 #35935 #35936
TypeScript Version: 3.8.0-dev.20191228
Search Terms:
Code
Expected behavior:
Error at
/*1*/and/*2*/since this syntax is not (yet) allowed. tc39/proposal-class-fields#4Thanks to Titian Cernicova-Dragomir (@dragomirtitian) for pointing this out.
Actual behavior:
No error.
Playground Link: https://www.typescriptlang.org/play/?ts=3.8.0-dev.20191228&ssl=7&ssc=2&pln=1&pc=1#code/MYGwhgzhAEDCDeAoaLoGIAOAnA9h6AvNAIwDcyqAtgKYAuAFjgCYAUAlNEqt9MDgHYRandNjwAuaGPwBfQtAYBLCOR6oW8UbgySlEAHSZt0OUT1tVqGYhlA
Related Issues: #35934 #35935 #35936