25 lines
No EOL
1 KiB
Text
25 lines
No EOL
1 KiB
Text
tests/cases/conformance/classes/indexMemberDeclarations/privateIndexer.ts(4,5): error TS1145: Modifiers not permitted on index signature members.
|
|
tests/cases/conformance/classes/indexMemberDeclarations/privateIndexer.ts(8,5): error TS1145: Modifiers not permitted on index signature members.
|
|
tests/cases/conformance/classes/indexMemberDeclarations/privateIndexer.ts(12,5): error TS1145: Modifiers not permitted on index signature members.
|
|
|
|
|
|
==== tests/cases/conformance/classes/indexMemberDeclarations/privateIndexer.ts (3 errors) ====
|
|
// private indexers not allowed
|
|
|
|
class C {
|
|
private [x: string]: string;
|
|
~~~~~~~
|
|
!!! error TS1145: Modifiers not permitted on index signature members.
|
|
}
|
|
|
|
class D {
|
|
private [x: number]: string;
|
|
~~~~~~~
|
|
!!! error TS1145: Modifiers not permitted on index signature members.
|
|
}
|
|
|
|
class E<T> {
|
|
private [x: string]: T;
|
|
~~~~~~~
|
|
!!! error TS1145: Modifiers not permitted on index signature members.
|
|
} |