Always exhaustively match on typing mode#155047
Always exhaustively match on typing mode#155047rust-bors[bot] merged 5 commits intorust-lang:mainfrom
Conversation
|
Some changes occurred in compiler/rustc_passes/src/check_attr.rs Some changes occurred to the CTFE machinery Some changes occurred to the CTFE / Miri interpreter cc @rust-lang/miri Some changes occurred in compiler/rustc_attr_parsing Some changes occurred to MIR optimizations cc @rust-lang/wg-mir-opt Some changes occurred in compiler/rustc_hir/src/attrs Some changes occurred to constck cc @fee1-dead changes to the core type system cc @lcnr |
63485a1 to
ef0684a
Compare
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
fcb4cae to
62dbaab
Compare
|
Some changes occurred in src/tools/clippy cc @rust-lang/clippy |
This comment has been minimized.
This comment has been minimized.
62dbaab to
791b38b
Compare
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
| let typing_env = ty::TypingEnv::new( | ||
| cx.typing_env.param_env, | ||
| ty::TypingMode::analysis_in_body(cx.tcx, cx.body.source.def_id().expect_local()), | ||
| ); |
There was a problem hiding this comment.
oh, this should use ty::TyingEnv::Borrowck or even PostBorrowckAnalysis with the new solver
compiler/rustc_trait_selection/src/traits/select/candidate_assembly.rs
Outdated
Show resolved
Hide resolved
791b38b to
6b67e10
Compare
6b67e10 to
19fd231
Compare
|
This PR was rebased onto a different main commit. Here's a range-diff highlighting what actually changed. Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers. |
This comment has been minimized.
This comment has been minimized.
19fd231 to
7760367
Compare
7760367 to
679d16b
Compare
|
@bors r=lcnr |
This comment has been minimized.
This comment has been minimized.
679d16b to
18d118a
Compare
|
This pull request was unapproved. |
|
@bors r=lcnr |
…uwer Rollup of 8 pull requests Successful merges: - #155047 (Always exhaustively match on typing mode) - #155080 (Simplify `try_load_from_disk_fn`.) - #152384 (Restrict EII declarations to functions at lowering time) - #153796 (Fix ICE when combining #[eii] with #[core::contracts::ensures]) - #154369 (Fix `pattern_from_macro_note` for bit-or expr) - #155027 ( Rename some more of our internal `#[rustc_*]` TEST attributes) - #155031 (delegation: fix unelided lifetime ICE, refactoring of GenericArgPosition) - #155040 (Fix code block whitespace handling in Markdown)
Rollup merge of #155047 - jdonszelmann:lint-against-eq-typing-mode, r=lcnr Always exhaustively match on typing mode r? @lcnr Unimplements Eq/PartialEq for TypingMode, adds TypingModeEqWrapper for the few cases where we need it (mainly in the query system), and adds a new rustc internal lint to detect cases where we non-exhaustively match on typing mode.
…uwer Rollup of 8 pull requests Successful merges: - rust-lang/rust#155047 (Always exhaustively match on typing mode) - rust-lang/rust#155080 (Simplify `try_load_from_disk_fn`.) - rust-lang/rust#152384 (Restrict EII declarations to functions at lowering time) - rust-lang/rust#153796 (Fix ICE when combining #[eii] with #[core::contracts::ensures]) - rust-lang/rust#154369 (Fix `pattern_from_macro_note` for bit-or expr) - rust-lang/rust#155027 ( Rename some more of our internal `#[rustc_*]` TEST attributes) - rust-lang/rust#155031 (delegation: fix unelided lifetime ICE, refactoring of GenericArgPosition) - rust-lang/rust#155040 (Fix code block whitespace handling in Markdown)
…ly-let-else, r=JonathanBrouwer `#[rustc_must_match_exhaustively]` detect let else Extension of rust-lang#155047, I forgor to lint on let-else :3
View all comments
r? @lcnr
Unimplements Eq/PartialEq for TypingMode, adds TypingModeEqWrapper for the few cases where we need it (mainly in the query system), and adds a new rustc internal lint to detect cases where we non-exhaustively match on typing mode.