TypeScript Version: playground (2.1.4-insiders.20161201)
Code
The following code should be run with the noImplicitAny set:
let f1: <T>(a: T) => T = a => a;
function f2<T>(a: T): T {
return a;
};
Expected behavior:
Both functions should compile fine.
Actual behavior:
The f1 arrow function fails the type check as the compiler thinks a is of any type.
TypeScript Version: playground (2.1.4-insiders.20161201)
Code
The following code should be run with the
noImplicitAnyset:Expected behavior:
Both functions should compile fine.
Actual behavior:
The
f1arrow function fails the type check as the compiler thinksais ofanytype.