TypeScript/tests/baselines/reference/emptyIndexer.js

18 lines
236 B
TypeScript
Raw Normal View History

2014-07-13 01:04:16 +02:00
//// [emptyIndexer.ts]
interface I1 {
m(): number;
}
interface I2 {
[s:string]: I1;
}
var x: I2;
var n = x[''].m(); // should not crash compiler
//// [emptyIndexer.js]
var x;
var n = x[''].m(); // should not crash compiler