Skip to content

Commit a12ef13

Browse files
committed
Auto merge of #5531 - montrivo:bugfix/3410-use_self_generic_false_positive, r=<try>
rework use_self impl based on ty::Ty comparison #3410 `use_self` lint refactoring. As suggested by `@eddyb` , implement the lint based on `ty::Ty` comparison instead of `hir::Path` checks. This PR introduces negative regressions. The cases were covered in the previous implementation. See the test file. It fixes #3410, #2843, #3859, #4734 and #4140. Should fix #4143 (example doesn't compile). #4305 false positive seems also fixed but the uitest fails to compile the unmodified test case in `use_self.rs.fixed`. Implements #5078. Generally the implementation checks are done at mir level and offers higher guarantees against false positives. It is probably fixing other unreported false positives. changelog: fix use_self generics false positives
2 parents 0b77c35 + f4c3d47 commit a12ef13

File tree

6 files changed

+704
-351
lines changed

6 files changed

+704
-351
lines changed

0 commit comments

Comments
 (0)