[Suggestion] should Overloads not differ only by return type? #11281
Labels
Suggestion
An idea for TypeScript
Won't Fix
The severity and priority of this issue do not warrant the time or complexity needed to fix it
I wonder if this is a bug. But at least this is a discrepancy between specification and implementation.
It appears in TS 1.03 function overloading cannot differ only by return type, but in TS1.1 this restriction was lifted.
SO question: http://stackoverflow.com/questions/25022331/overloads-cannot-differ-only-by-return-type
Source: https://github.com/Microsoft/TypeScript/blob/release-1.0.3/src/compiler/resources/diagnosticMessages.json#L1024
Spec: https://github.com/Microsoft/TypeScript/blob/master/doc/spec.md#1212-ambient-function-declarations
This should also impact call signatures in intersection types.
The text was updated successfully, but these errors were encountered: