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
Infer input type of lambda based on 2nd argument to map() #438
This is a bit tricky, we'll need to use the type of the second argument to map's constructor as part of the contextual type for the first argument. Right now I suspect we're just evaluating arguments left to right.
changed the title [-]map() does not infer types for lambda expressions[/-][+]Infer input type of lambda based on 2nd argument to map()[/+]on Jun 16, 2025
Making contextual typing work for calls like this is part of the scope of #105. Going to leave this open because it's a good example, and we could solve #105 without fixing this in theory.
Activity
yangdanny97 commentedon Jun 16, 2025
This is a bit tricky, we'll need to use the type of the second argument to map's constructor as part of the contextual type for the first argument. Right now I suspect we're just evaluating arguments left to right.
[-]map() does not infer types for lambda expressions[/-][+]Infer input type of lambda based on 2nd argument to map()[/+]samwgoldman commentedon Jan 15, 2026
Making contextual typing work for calls like this is part of the scope of #105. Going to leave this open because it's a good example, and we could solve #105 without fixing this in theory.
fix Infer input type of lambda based on 2nd argument to map() #438 (#…