58 lines
No EOL
2.1 KiB
Text
58 lines
No EOL
2.1 KiB
Text
tests/cases/compiler/noCollisionThisExpressionAndLocalVarInAccessors.ts(2,9): error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
|
|
tests/cases/compiler/noCollisionThisExpressionAndLocalVarInAccessors.ts(12,9): error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
|
|
tests/cases/compiler/noCollisionThisExpressionAndLocalVarInAccessors.ts(24,9): error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
|
|
tests/cases/compiler/noCollisionThisExpressionAndLocalVarInAccessors.ts(34,9): error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
|
|
|
|
|
|
==== tests/cases/compiler/noCollisionThisExpressionAndLocalVarInAccessors.ts (4 errors) ====
|
|
class class1 {
|
|
get a(): number {
|
|
~
|
|
!!! error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
|
|
var x2 = {
|
|
doStuff: (callback) => () => {
|
|
var _this = 2;
|
|
return callback(_this);
|
|
}
|
|
}
|
|
|
|
return 10;
|
|
}
|
|
set a(val: number) {
|
|
~
|
|
!!! error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
|
|
var x2 = {
|
|
doStuff: (callback) => () => {
|
|
var _this = 2;
|
|
return callback(_this);
|
|
}
|
|
}
|
|
|
|
}
|
|
}
|
|
|
|
class class2 {
|
|
get a(): number {
|
|
~
|
|
!!! error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
|
|
var _this = 2;
|
|
var x2 = {
|
|
doStuff: (callback) => () => {
|
|
return callback(_this);
|
|
}
|
|
}
|
|
|
|
return 10;
|
|
}
|
|
set a(val: number) {
|
|
~
|
|
!!! error TS1056: Accessors are only available when targeting ECMAScript 5 and higher.
|
|
var _this = 2;
|
|
var x2 = {
|
|
doStuff: (callback) => () => {
|
|
return callback(_this);
|
|
}
|
|
}
|
|
|
|
}
|
|
} |