-
Notifications
You must be signed in to change notification settings - Fork 13.4k
ICE: unmatched subst and hir arg #82126
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
Labels
A-borrow-checker
Area: The borrow checker
A-diagnostics
Area: Messages for errors, warnings, and lints
C-bug
Category: This is a bug.
E-easy
Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.
E-help-wanted
Call for participation: Help is requested to fix this issue.
glacier
ICE tracked in rust-lang/glacier.
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.
Comments
Smaller: use std::sync::Mutex;
struct MarketMultiplier {}
impl MarketMultiplier {
fn buy(&mut self) -> &mut usize {
todo!()
}
}
async fn buy_lock(generator: &Mutex<MarketMultiplier>) -> LockedMarket<'_> {
LockedMarket(generator.lock().unwrap().buy())
}
struct LockedMarket<T>(T);
fn main() {} |
Relevant code: rust/compiler/rustc_mir/src/borrow_check/diagnostics/region_name.rs Lines 637 to 645 in 9503ea1
So I think that just needs to be a |
I've actually been looking to contribute to Rust—would this be a good first issue to tackle? |
This would definitely be a good first issue! |
fanninpm
added a commit
to fanninpm/glacier
that referenced
this issue
Feb 16, 2021
Issue: rust-lang/rust#82126
Dylan-DPC-zz
pushed a commit
to Dylan-DPC-zz/rust
that referenced
this issue
Feb 16, 2021
…r, r=lcnr Fix ICE: Use delay_span_bug for mismatched subst/hir arg Fixes rust-lang#82126.
Dylan-DPC-zz
pushed a commit
to Dylan-DPC-zz/rust
that referenced
this issue
Feb 17, 2021
…r, r=lcnr Fix ICE: Use delay_span_bug for mismatched subst/hir arg Fixes rust-lang#82126.
# for free
to join this conversation on GitHub.
Already have an account?
# to comment
Labels
A-borrow-checker
Area: The borrow checker
A-diagnostics
Area: Messages for errors, warnings, and lints
C-bug
Category: This is a bug.
E-easy
Call for participation: Easy difficulty. Experience needed to fix: Not much. Good first issue.
E-help-wanted
Call for participation: Help is requested to fix this issue.
glacier
ICE tracked in rust-lang/glacier.
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.
Code
The following is an attempted minimum reproducible sample that causes ICE. From a few minutes of experimentation, I wasn't able to further minimize the example, but I feel as if it should be possible (perhaps an example can be formed with just an async boundary and a mutex?).
Meta
rustc --version --verbose
:Also saw the ICE on nightly, but I can't seem to get my instance of cargo to recognize the 1.52 toolchain. Testing on playgound shows this still is present:
Error output
The following outputs are the result of building on nightly playgound:
Backtrace
The text was updated successfully, but these errors were encountered: