5 lines
No EOL
330 B
Text
5 lines
No EOL
330 B
Text
==== tests/cases/compiler/contextualTyping39.ts (1 errors) ====
|
|
var foo = <{ (): number; }> function() { return "err"; };
|
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|
!!! Neither type '() => string' nor type '() => number' is assignable to the other:
|
|
!!! Type 'string' is not assignable to type 'number'. |