Run AST validation on match guards correctly#111841
Conversation
|
r? @eholk (rustbot has picked a reviewer for you, use r? to override) |
|
Not sure if this deserves a crater run or not. |
Let's do it anyways. I'd be inclined to land it either way, but let's find out now if we need any fixes instead of during beta crater runs. @bors try |
|
⌛ Trying commit 72d41f3 with merge 6ce3e686a73dccf860e3697301749a5a1fe143c5... |
| let category = Category::of(&expr.kind).unwrap(); | ||
| debug!(?category, ?expr.kind); | ||
| match category { | ||
| Category::Constant if let NeedsTemporary::No = needs_temporary || !expr.ty.needs_drop(this.tcx, this.param_env) => { |
There was a problem hiding this comment.
It's somewhat concerning that this was living in the compiler 😅
There was a problem hiding this comment.
"Why is rust analyzer complaning about this file? Wait, why is rustc compiling this file?"
|
☀️ Try build successful - checks-actions |
|
@craterbot check |
|
👌 Experiment ℹ️ Crater is a tool to run experiments across parts of the Rust ecosystem. Learn more |
|
🚧 Experiment ℹ️ Crater is a tool to run experiments across parts of the Rust ecosystem. Learn more |
|
Anyways, r=me if crater comes back clean. If it doesn't, then I still think we should land it, but maybe worth compiler-nominating and opening up some preemptive fix PRs. |
|
🎉 Experiment
|
|
Regressions look supurious. |
…iaskrgr Rollup of 6 pull requests Successful merges: - rust-lang#111121 (Work around `rust-analyzer` false-positive type errors) - rust-lang#111759 (Leverage the interval property to precompute borrow kill points.) - rust-lang#111841 (Run AST validation on match guards correctly) - rust-lang#111862 (Split out opaque collection from from `type_of`) - rust-lang#111863 (Don't skip mir typeck if body has errors) - rust-lang#111903 (Migrate GUI colors test to original CSS color format) r? `@ghost` `@rustbot` modify labels: rollup
AST validation was being skipped on match guards other than
if letguards.