You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
"This expression is not callable." false positive on union of generic functions where the call is valid for all types in the unionΒ #64855
This expression is not callable.
Each member of the union type '(<T>(value: T) => T) | (<T extends number>(value: T) => T)' has signatures, but none of those signatures are compatible with each other.
π Expected behavior
no error, since the call is valid for both function types in the union
This is a known limitation of the work in #29011 to address #7294. Currently a union of call signatures can have at most one overloaded member and one generic member. Here you have two generic members, so TS does not try to unify. Not sure if this will be closed as a design limitation, or kept open as a feature request to try again to look at unification, but it's not considered a bug.
Activity
jcalz commentedon Oct 18, 2026
This is a known limitation of the work in #29011 to address #7294. Currently a union of call signatures can have at most one overloaded member and one generic member. Here you have two generic members, so TS does not try to unify. Not sure if this will be closed as a design limitation, or kept open as a feature request to try again to look at unification, but it's not considered a bug.