swc/crates/swc_ecma_parser/tests/tsc/classStaticBlock11.ts
2022-02-04 17:08:38 +09:00

15 lines
202 B
TypeScript

// @target: esnext, es2022, es2015
let getX;
class C {
#x = 1
constructor(x: number) {
this.#x = x;
}
static {
// getX has privileged access to #x
getX = (obj: C) => obj.#x;
}
}