TypeScript/tests/cases/compiler/genericFunctionCallSignatureReturnTypeMismatch.ts

11 lines
142 B
TypeScript
Raw Normal View History

2014-07-13 01:04:16 +02:00
interface Array<T> {}
var f : { <T>(x:T): T; }
var g : { <S>() : S[]; };
f = g;
var s = f("str").toUpperCase();
console.log(s);