23 lines
391 B
TypeScript
23 lines
391 B
TypeScript
//// [interfaceWithStringIndexerHidingBaseTypeIndexer2.ts]
|
|
interface Base {
|
|
[x: number]: { a: number; b: number }
|
|
x: {
|
|
a: number; b: number;
|
|
}
|
|
}
|
|
|
|
interface Derived extends Base {
|
|
[x: string]: {
|
|
a: number
|
|
};
|
|
|
|
y: {
|
|
a: number;
|
|
}
|
|
// error
|
|
1: {
|
|
a: number;
|
|
}
|
|
}
|
|
|
|
//// [interfaceWithStringIndexerHidingBaseTypeIndexer2.js]
|