Reverse mapped type inference fails to infer from annotated parameters in partially-inferrable object types #57788
Labels
Help Wanted
You can do this
Possible Improvement
The current behavior isn't wrong, but it's possible to see that it might be better in some cases
Milestone
π Search Terms
reverse mapped inference annotated parameters partially inferrable noninferrable object context sensitive
π Version & Regression Information
β― Playground Link
https://www.typescriptlang.org/play?ts=5.5.0-dev.20240315#code/CYUwxgNghgTiAEAzArgOzAFwJYHtXwGcQNkAHAHgBUBxZWYAgPgAoB9ALngG8AoeeAOZ0YDTr378A2gGl4WfAGsQATxyJ4NYQwC6nZpgAenNAtQ4A7qgA08UrCgBbAp030CM7QEp4AXkbwAIxwcCBAoVABuPngAXyiYzxdaNyieMDwCDEEtAl9CYjJmcWy3MWj+KD1vP3gMGGQQK3LAvVYbOxhHAmr-OoamiXgwVvb7J05UZAcAkBge2vrG6JimhNShNx4Aei34AD0AfiA
π» Code
π Actual behavior
It infers
{ a: unknown; b: unknown; c: unknown; }
π Expected behavior
I'd expect
{ a: unknown; b: unknown; c: number; }
to get inferred hereAdditional information about the issue
No response
The text was updated successfully, but these errors were encountered: