rust/compiler/rustc_mir_build
Manish Goregaokar fbc67b59a1
Rollup merge of #89314 - notriddle:notriddle/lint-fix-enum-variant-match, r=davidtwco
fix(lint): don't suggest refutable patterns to "fix" irrefutable bind

In function arguments and let bindings, do not suggest changing `C` to `Foo::C` unless `C` is the only variant of `Foo`, because it won't work.

The general warning is still kept, because code like this is confusing.

Fixes #88730

p.s. `src/test/ui/lint/lint-uppercase-variables.rs` already tests the one-variant case.
2021-09-30 18:05:25 -07:00
..
src Rollup merge of #89314 - notriddle:notriddle/lint-fix-enum-variant-match, r=davidtwco 2021-09-30 18:05:25 -07:00
Cargo.toml Migrate to 2021 2021-09-20 22:21:42 -04:00