Files
rust/tests
Matthias Krüger 224aab4223 Rollup merge of #148262 - JonathanBrouwer:dead-code-inference, r=nnethercote
Fix types being marked as dead when they are inferred generic arguments

Previously usages of a type in a pattern were ignored. This is incorrect, since if the type is in a pattern we're clearly producing it in the expression we're matching against.

I think this `in_pat` check was meant to be only for variants, which we should indeed ignore since we can just remove the match arm that matches the pattern. Please double check my logic here since this is my first time touching the dead-code pass and I'm not 100% sure this is what the `self.in_pat` check was for.

Fixes https://github.com/rust-lang/rust/issues/148144
2025-10-31 02:39:17 +01:00
..
2025-10-29 13:15:12 +00:00
2025-10-27 21:19:38 -05:00