Files
tsgo/testdata/baselines/reference/submodule/conformance/emitClassDeclarationWithGetterSetterInES6.errors.txt

33 lines
996 B
Plaintext

emitClassDeclarationWithGetterSetterInES6.ts(2,5): error TS2564: Property '_name' has no initializer and is not definitely assigned in the constructor.
==== emitClassDeclarationWithGetterSetterInES6.ts (1 errors) ====
class C {
_name: string;
~~~~~
!!! error TS2564: Property '_name' has no initializer and is not definitely assigned in the constructor.
get name(): string {
return this._name;
}
static get name2(): string {
return "BYE";
}
static get ["computedname"]() {
return "";
}
get ["computedname1"]() {
return "";
}
get ["computedname2"]() {
return "";
}
set ["computedname3"](x: any) {
}
set ["computedname4"](y: string) {
}
set foo(a: string) { }
static set bar(b: number) { }
static set ["computedname"](b: string) { }
}