ICE: "broken MIR in DefId" when assigning mismatched closure to FnMut
#53448
Labels
A-closures
Area: Closures (`|…| { … }`)
A-MIR
Area: Mid-level IR (MIR) - https://blog.rust-lang.org/2016/04/19/MIR.html
C-bug
Category: This is a bug.
E-needs-test
Call for participation: An issue has been fixed and does not reproduce, but no test has been added.
F-unboxed_closures
`#![feature(unboxed_closures)]`
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.
The following code
causes panic with message
which is irrelevant to the code. Simply modify
link_binary
function in src\librustc_codegen_llvm\back\link.rs to make it panic before return, will then output some result that saysThis is a variation of #53420 aka #29997, but is more serious and we should fix this first to make it at least emit the real error.
The proper fix of this issue, is NOT to make the code above compile; instead, it should give ICE with proper messages instead of something irrelevant so that we ensure we can get useful information from ICEs all the time, and the ICE is to be fixed after #53420 aka #29997.
The text was updated successfully, but these errors were encountered: