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
constdoSomething=<B,>(argB: B)=>{};doSomething("foo");// Works as expectedconstdoSomethingElse=<A,B>(argB: B)=>{};doSomethingElse<"bar">("foo");// Error: Expected 2 type arguments, but got 1
π Actual behavior
TypeScript throws an error in the second example despite being able to infer the type in the first one
π Expected behavior
No error, TypeScript infers the second type as "foo", since it is provided as an parameter
The text was updated successfully, but these errors were encountered:
Bug Report
π Search Terms
π Version & Regression Information
β― Playground Link
Playground link with relevant code
π» Code
π Actual behavior
TypeScript throws an error in the second example despite being able to infer the type in the first one
π Expected behavior
No error, TypeScript infers the second type as "foo", since it is provided as an parameter
The text was updated successfully, but these errors were encountered: