-
-
Notifications
You must be signed in to change notification settings - Fork 14.9k
compiler panicked at 'Box<Any>' #61664
Copy link
Copy link
Closed
Labels
A-async-awaitArea: Async & AwaitArea: Async & AwaitA-coroutinesArea: CoroutinesArea: CoroutinesC-bugCategory: This is a bug.Category: This is a bug.I-ICEIssue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.
Metadata
Metadata
Assignees
Labels
A-async-awaitArea: Async & AwaitArea: Async & AwaitA-coroutinesArea: CoroutinesArea: CoroutinesC-bugCategory: This is a bug.Category: This is a bug.I-ICEIssue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.Relevant to the compiler team, which will review and decide on the PR/issue.
Type
Fields
Give feedbackNo fields configured for issues without a type.
Hi, I was working on a project on 1.36.0 nightly and when I upgraded to 1.37.0 nightly (rustc 1.37.0-nightly (d132f54 2019-06-07) running on x86_64-unknown-linux-gnu) I got an internal compiler error.
https://github.com/JuanPotato/XKCD-search-bot/tree/d7624b25fbeb57975b54a19d9c8e8103b0d261a4 is the project, and the current code should cause this error
Error log
error: internal compiler error: src/librustc_mir/transform/generator.rs:532: Broken MIR: generator contains type std::option::Option in MIR, but typeck only knows about for<'r, 's, 't0, 't1, 't2> {std::sync::Arc, impl Iterator, std::collections::HashMap, std::iter::Filter, [closure@src/scraper.rs:71:43: 71:56]>, futures_channel::mpsc::Sender<(scraper::XkcdInfo, usize)>, futures_channel::mpsc::Receiver<(scraper::XkcdInfo, usize)>, std::vec::Vec>, fn(std::ops::Range) -> as std::iter::IntoIterator>::IntoIter { as std::iter::IntoIterator>::into_iter}, usize, std::ops::Range, &'r mut std::iter::Filter, [closure@src/scraper.rs:71:43: 71:56]>, std::option::Option, futures_channel::mpsc::Sender, futures_channel::mpsc::Receiver, impl core::future::future::Future, futures_util::sink::send::Send<'s, futures_channel::mpsc::Sender, usize>, (), futures_util::stream::next::Next<'t0, futures_channel::mpsc::Receiver<(scraper::XkcdInfo, usize)>>, std::option::Option<(scraper::XkcdInfo, usize)>, scraper::XkcdInfo, &'t1 mut std::iter::Filter, [closure@src/scraper.rs:71:43: 71:56]>, futures_util::sink::send::Send<'t2, futures_channel::mpsc::Sender, usize>} --> src/scraper.rs:70:32 | 70 | ) -> HashMap { | ________________________________^ 71 | | let mut xkcd_nums = comic_nums.filter(|&n| n != 404); // remove 404 if found 72 | | 73 | | const MAX_WORKERS: usize = 250; ... | 104 | | xkcd_comics 105 | | } | |_^ thread 'rustc' panicked at 'Box', src/librustc_errors/lib.rs:573:9 note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace. error: aborting due to previous error note: the compiler unexpectedly panicked. this is a bug. note: we would appreciate a bug report: https://github.com/rust-lang/rust/blob/master/CONTRIBUTING.md#bug-reports note: rustc 1.37.0-nightly (d132f544f 2019-06-07) running on x86_64-unknown-linux-gnu note: compiler flags: -C opt-level=3 --crate-type bin note: some of the compiler flags provided by cargo are hidden