functions with destructuring parameters are not inferred as type predicate correctly #59497
Labels
Awaiting More Feedback
This means we'd like to hear from more people who would be helped by this feature
Suggestion
An idea for TypeScript
🔎 Search Terms
infer type predicate, destructuring
🕗 Version & Regression Information
⏯ Playground Link
https://www.typescriptlang.org/play/?#code/C4TwDgpgBAGlC8UDeVSQFxQOQEEsG4oBDTAZ2ACcBLAOwHMoBfKAH2VXAkywCECoARmUq0GjfACgANhGBQAHqUwwA2gF0EUdZIkB6XVFIALAPYBXKQBMoNE3IgUKJihIDGJmuSgAzKlOAOEJYAjJgoaFzYeIQkhiL0TOqaihJQUAB0vv4OABQ54ZxMAJQIAHwckAjwiLhYRTrunnJZARRBAExhFZG1McLUCYxJiClpmX6tOfJlCukRVTV49RJAA
💻 Code
🙁 Actual behavior
error on filtered1
🙂 Expected behavior
not error on filtered1
Additional information about the issue
No response
The text was updated successfully, but these errors were encountered: