-
Notifications
You must be signed in to change notification settings - Fork 13.2k
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
unify IsPattern
and IsImport
enum in show_candidates
#102913
Conversation
/// Whether a binding is part of a pattern or an expression. Used for diagnostics. | ||
enum IsPattern { | ||
/// Whether a binding is part of a pattern or a use statement. Used for diagnostics. | ||
enum Mode { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe DiagnosticMode
? r=me after giving it a better name than just Mode
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done. But I don't have privileges, so I still need you to r+
09e55ab
to
a7f58af
Compare
@bors r=compiler-errors |
@SparrowLii: 🔑 Insufficient privileges: Not in reviewers |
I will r+ it once CI turns green. |
@bors r+ rollup |
Rollup of 8 pull requests Successful merges: - rust-lang#102110 (Migrate rustc_passes diagnostics) - rust-lang#102187 (Use correct location for type tests in promoted constants) - rust-lang#102239 (Move style guide to rust-lang/rust) - rust-lang#102578 (Panic for invalid arguments of `{integer primitive}::ilog{,2,10}` in all modes) - rust-lang#102811 (Use memset to initialize readbuf) - rust-lang#102890 (Check representability in adt_sized_constraint) - rust-lang#102913 (unify `IsPattern` and `IsImport` enum in `show_candidates`) - rust-lang#102924 (rustdoc: remove unused classes from sidebar links) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
Follow-up of #102876
A binding cannot appear in both pattern and import at the same time, so it makes sense to unify them
r? @compiler-errors