mirror of
https://github.com/swc-project/swc.git
synced 2024-12-28 08:04:43 +03:00
18 lines
357 B
TypeScript
18 lines
357 B
TypeScript
// @allowJs: true
|
|
// @checkJs: true
|
|
// @emitDeclarationOnly: true
|
|
// @strict: true
|
|
// @target: es6
|
|
// @declaration: true
|
|
// @filename: lateBoundClassMemberAssignmentJS.js
|
|
const _sym = Symbol("_sym");
|
|
export class MyClass {
|
|
constructor() {
|
|
this[_sym] = "ok";
|
|
}
|
|
|
|
method() {
|
|
this[_sym] = "yep";
|
|
const x = this[_sym];
|
|
}
|
|
} |