-
Notifications
You must be signed in to change notification settings - Fork 12.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
let_chains causes a compiler panic #82290
Labels
C-bug
Category: This is a bug.
F-let_chains
`#![feature(let_chains)]`
glacier
ICE tracked in rust-lang/glacier.
I-ICE
Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️
P-medium
Medium priority
requires-nightly
This issue requires a nightly compiler in some way.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Comments
irevoire
added
C-bug
Category: This is a bug.
I-ICE
Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
labels
Feb 19, 2021
MCVE (playground): #![feature(let_chains)]
fn main() {
if true && let x = 1 {
let _ = x;
}
} |
jyn514
added
F-let_chains
`#![feature(let_chains)]`
requires-nightly
This issue requires a nightly compiler in some way.
labels
Feb 19, 2021
jyn514
changed the title
str_split_once + let_chains cause compiler panic
let_chains causes a compiler panic
Feb 19, 2021
Probably a duplicate of #82250. |
I think I found the problem, lowering not being done in source order would cause this. The block of the then expression was being lowered before the condition, leading to the node corresponding to the |
This was referenced Feb 20, 2021
fanninpm
added a commit
to fanninpm/glacier
that referenced
this issue
Feb 20, 2021
Issue: rust-lang/rust#82290
Dylan-DPC-zz
pushed a commit
to Dylan-DPC-zz/rust
that referenced
this issue
Feb 23, 2021
Lower condition of `if` expression before it's "then" block Fix rust-lang#82290, fix rust-lang#82250.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
C-bug
Category: This is a bug.
F-let_chains
`#![feature(let_chains)]`
glacier
ICE tracked in rust-lang/glacier.
I-ICE
Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️
P-medium
Medium priority
requires-nightly
This issue requires a nightly compiler in some way.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
Code
Meta
rustc --version --verbose
:Error output
Backtrace
I made a small git repo to reproduce the bug here
The text was updated successfully, but these errors were encountered: