]> git.lizzy.rs Git - rust.git/commitdiff
Rollup merge of #98431 - WaffleLapkin:mut_pat_suggestions, r=compiler-errors
authorMatthias Krüger <matthias.krueger@famsik.de>
Sat, 25 Jun 2022 13:14:14 +0000 (15:14 +0200)
committerGitHub <noreply@github.com>
Sat, 25 Jun 2022 13:14:14 +0000 (15:14 +0200)
Suggest defining variable as mutable on `&mut _` type mismatch in pats

Suggest writing `mut a` where `&mut a` was written but a non-ref type provided.

Since we still don't have "apply either one of the suggestions but not both" kind of thing, the interaction with the suggestion of removing `&[mut]` or moving it to the type is weird, and idk how to make it better..

r? ``@compiler-errors``


Trivial merge