Closed
Description
I am following the Bevy Tutorial and encountered the following compiler panic.
I followed the suggested compilation time optimisations from Bevy: Bevy Tutorial - Setup (Scroll down to "Enable Fast Compilation").
Furthermore, I am using sccache.
However, with or without those changes, I get the same panic.
Code
src/main.rs
:
use bevy::prelude::*;
fn hello_world() {
println!("Hello, world!");
}
fn main() {
App::build().add_system(hello_world.system()).run();
}
Cargo.toml
:
[package]
name = "bevy_tutorial"
version = "0.1.0"
authors = ["Lukas Weber <me@sakul6499.de>"]
edition = "2018"
[dependencies]
bevy = "0.5.0"
~/.cargo/config
:
# SCCACHE
[build]
rustc-wrapper = "sccache"
[target.x86_64-unknown-linux-gnu]
linker = "/usr/bin/clang"
rustflags = ["-Clink-arg=-fuse-ld=lld", "-Zshare-generics=y"]
[target.x86_64-apple-darwin] # `brew install michaeleisel/zld/zld`
rustflags = [
"-C",
"link-arg=-fuse-ld=/usr/local/bin/zld",
"-Zshare-generics=y",
"-Csplit-debuginfo=unpacked"
]
[target.x86_64-pc-windows-msvc]
linker = "rust-lld.exe"
rustflags = ["-Zshare-generics=y"]
# Optional: Uncommenting the following improves compile times, but reduces the amount of debug info to 'line
number tables only'
# In most cases the gains are negligible, but if you are on macos and have slow compile times you should see
significant gains.
#[profile.dev]
#debug = 1
Meta
rustc --version --verbose
:
rustc 1.53.0-nightly (07e0e2ec2 2021-03-24)
binary: rustc
commit-hash: 07e0e2ec268c140e607e1ac7f49f145612d0f597
commit-date: 2021-03-24
host: x86_64-pc-windows-msvc
release: 1.53.0-nightly
LLVM version: 12.0.0
Error output
Compiling bevy_tutorial v0.1.0 (C:\Users\me\OneDrive\Workspace\bevy_tutorial)
thread 'rustc' panicked at 'found unstable fingerprints for predicates_of(core[f48f]::ops::function::FnMut):
GenericPredicates { parent: None, predicates: [(Binder(TraitPredicate(<Self as std::ops::FnOnce<Args>>)), C:\Users\me\scoop\persist\rustup-msvc\.rustup\toolchains\nightly-x86_64-pc-windows-msvc\lib/rustlib/src/rust\library\core\src\ops\function.rs:147:24: 147:36 (#0)), (Binder(TraitPredicate(<Args as std::marker::Sized>)), C:\Users\me\scoop\persist\rustup-msvc\.rustup\toolchains\nightly-x86_64-pc-windows-msvc\lib/rustlib/src/rust\library\core\src\ops\function.rs:147:17: 147:21 (#0)), (Binder(TraitPredicate(<Self as std::ops::FnMut<Args>>)), C:\Users\me\scoop\persist\rustup-msvc\.rustup\toolchains\nightly-x86_64-pc-windows-msvc\lib/rustlib/src/rust\library\core\src\ops\function.rs:147:1: 147:36 (#0))] }', /rustc/07e0e2ec268c140e607e1ac7f49f145612d0f597\compiler\rustc_query_system\src\query\plumbing.rs:593:5
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
error: internal compiler error: unexpected panic
note: the compiler unexpectedly panicked. this is a bug.
note: we would appreciate a bug report: https://github.com/rust-lang/rust/issues/new?labels=C-bug%2C+I-ICE%2C+T-compiler&template=ice.md
note: rustc 1.53.0-nightly (07e0e2ec2 2021-03-24) running on x86_64-pc-windows-msvc
note: compiler flags: -Z share-generics=y -Z share-generics=y -C embed-bitcode=no -C debuginfo=2 -C linker=rust-lld.exe -C incremental --crate-type bin
note: some of the compiler flags provided by cargo are hidden
query stack during panic:
#0 [predicates_of] computing predicates of `std::ops::FnMut`
#1 [param_env] computing normalized predicates of `std::ops::FnMut::call_mut`
end of query stack
error: could not compile `bevy_tutorial`
To learn more, run the command again with --verbose.
Backtrace
Compiling bevy_tutorial v0.1.0 (C:\Users\me\OneDrive\Workspace\bevy_tutorial)
thread 'rustc' panicked at 'found unstable fingerprints for predicates_of(core[f48f]::ops::function::FnMut):
GenericPredicates { parent: None, predicates: [(Binder(TraitPredicate(<Self as std::ops::FnOnce<Args>>)), C:\Users\me\scoop\persist\rustup-msvc\.rustup\toolchains\nightly-x86_64-pc-windows-msvc\lib/rustlib/src/rust\library\core\src\ops\function.rs:147:24: 147:36 (#0)), (Binder(TraitPredicate(<Args as std::marker::Sized>)), C:\Users\me\scoop\persist\rustup-msvc\.rustup\toolchains\nightly-x86_64-pc-windows-msvc\lib/rustlib/src/rust\library\core\src\ops\function.rs:147:17: 147:21 (#0)), (Binder(TraitPredicate(<Self as std::ops::FnMut<Args>>)), C:\Users\me\scoop\persist\rustup-msvc\.rustup\toolchains\nightly-x86_64-pc-windows-msvc\lib/rustlib/src/rust\library\core\src\ops\function.rs:147:1: 147:36 (#0))] }', /rustc/07e0e2ec268c140e607e1ac7f49f145612d0f597\compiler\rustc_query_system\src\query\plumbing.rs:593:5
stack backtrace:
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
error: internal compiler error: unexpected panic
note: the compiler unexpectedly panicked. this is a bug.
note: we would appreciate a bug report: https://github.com/rust-lang/rust/issues/new?labels=C-bug%2C+I-ICE%2C+T-compiler&template=ice.md
note: rustc 1.53.0-nightly (07e0e2ec2 2021-03-24) running on x86_64-pc-windows-msvc
note: compiler flags: -Z share-generics=y -Z share-generics=y -C embed-bitcode=no -C debuginfo=2 -C linker=rust-lld.exe -C incremental --crate-type bin
note: some of the compiler flags provided by cargo are hidden
query stack during panic:
#0 [predicates_of] computing predicates of `std::ops::FnMut`
#1 [param_env] computing normalized predicates of `std::ops::FnMut::call_mut`
#2 [mir_shims] generating MIR shim for `std::ops::FnMut::call_mut`
#3 [collect_and_partition_mono_items] collect_and_partition_mono_items
end of query stack
error: could not compile `bevy_tutorial`
To learn more, run the command again with --verbose.