TypeScript/tests/cases/compiler/defaultBestCommonTypesHaveDecls.ts
2014-07-12 17:30:19 -07:00

18 lines
241 B
TypeScript

var obj1: {};
obj1.length;
var obj2: Object;
obj2.length;
function concat<T>(x: T, y: T): T { return null; }
var result = concat(1, "");
var elementCount = result.length; // would like to get an error by now