Open
Description
It would seem that the compiler isn't resolving the type for a generic function that is being passed in as an argument where the type should be resolvable.
Example Code:
function freeFunction<T>(value: T): T {
return value;
}
function bad<T>(value: T, func: (value: T) => T): T {
return func(value);
}
export function test(): i64 {
return bad<i64>(123, freeFunction);
}
WebAssembly Studio Example: https://webassembly.studio/?f=gpmwo8wi18h
Error:
ERROR TS2554: Expected 1 arguments, but got 0.
return bad<i64>(123, freeFunction);
~~~~~~~~~~~~
in main.ts(10,24)
FAILURE 1 compile error(s)