tests/cases/compiler/genericGetter3.ts(5,9): error TS1056: Accessors are only available when targeting ECMAScript 5 and higher. tests/cases/compiler/genericGetter3.ts(11,5): error TS2322: Type 'A' is not assignable to type 'string'. ==== tests/cases/compiler/genericGetter3.ts (2 errors) ==== class A { } class C { data: A; get x(): A { ~ !!! error TS1056: Accessors are only available when targeting ECMAScript 5 and higher. return this.data; } } var c = new C(); var r: string = c.x; ~ !!! error TS2322: Type 'A' is not assignable to type 'string'.