TypeScript/tests/baselines/reference/twoAccessorsWithSameName2.errors.txt
2014-07-12 17:30:19 -07:00

33 lines
1.1 KiB
Plaintext

==== tests/cases/conformance/classes/propertyMemberDeclarations/twoAccessorsWithSameName2.ts (8 errors) ====
class C {
static get x() { return 1; }
~
!!! Accessors are only available when targeting ECMAScript 5 and higher.
static get x() { return 1; } // error
~
!!! Accessors are only available when targeting ECMAScript 5 and higher.
~
!!! Duplicate identifier 'x'.
}
class D {
static set x(v) { }
~
!!! Accessors are only available when targeting ECMAScript 5 and higher.
static set x(v) { } // error
~
!!! Accessors are only available when targeting ECMAScript 5 and higher.
~
!!! Duplicate identifier 'x'.
}
class E {
static get x() {
~
!!! Accessors are only available when targeting ECMAScript 5 and higher.
return 1;
}
static set x(v) { }
~
!!! Accessors are only available when targeting ECMAScript 5 and higher.
}