Skip to content
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

ICE: Compiling minimal Bevy snippet on nightly: assertion failed: !value.has_escaping_bound_vars() #95060

Closed
Dentosal opened this issue Mar 18, 2022 · 2 comments
Labels
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.

Comments

@Dentosal
Copy link

Code

Cargo.toml

[package]
name = "bug-repro"
version = "0.1.0"
edition = "2021"

[dependencies]
bevy = "0.6"

src/main.rs

use bevy::prelude::*;

fn main() {
    App::new()
        .add_plugins(DefaultPlugins)
        .run();
}

Meta

rustc --version --verbose:

> rustc --version --verbose
rustc 1.61.0-nightly (461e80780 2022-03-16)
binary: rustc
commit-hash: 461e8078010433ff7de2db2aaae8a3cfb0847215
commit-date: 2022-03-16
host: x86_64-pc-windows-msvc
release: 1.61.0-nightly
LLVM version: 14.0.0

Error output

> cargo run
   Compiling tracing-subscriber v0.3.9
   Compiling bevy_log v0.6.0
   Compiling bevy_diagnostic v0.6.0
   Compiling bevy_asset v0.6.0
thread 'rustc' panicked at 'assertion failed: !value.has_escaping_bound_vars()', /rustc/461e8078010433ff7de2db2aaae8a3cfb0847215\compiler\rustc_middle\src\ty\sty.rs:1089:9
stack backtrace:
   0:     0x7fff4339984f - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::h209c472627563299
   1:     0x7fff433cf79a - core::fmt::write::h567c2998d9f04c5b
   2:     0x7fff4338c6f9 - <std::io::IoSlice as core::fmt::Debug>::fmt::h1c6b5d0d4809fd35
   3:     0x7fff4339cddb - std::panicking::default_hook::ha3016e0f35887857
   4:     0x7fff4339c9ce - std::panicking::default_hook::ha3016e0f35887857
   5:     0x7ffeee2e2a49 - <rustc_driver[82344853edd39501]::args::Error as core[6a08d9f219683c56]::fmt::Debug>::fmt
   6:     0x7fff4339d6ba - std::panicking::rust_panic_with_hook::h39970c8f58689eba
   7:     0x7fff4339d3d2 - <std::panicking::begin_panic_handler::StrPanicPayload as core::panic::BoxMeUp>::get::h3aa15052fb94e4d8
   8:     0x7fff4339a157 - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::h209c472627563299
   9:     0x7fff4339d0e9 - rust_begin_unwind
  10:     0x7fff43403245 - core::panicking::panic_fmt::h3af7e985b6002e2f
  11:     0x7fff434030ec - core::panicking::panic::h446e057d93fe73a8
  12:     0x7ffef26d5029 - rustc_trait_selection[3b407de960b1d079]::traits::type_known_to_meet_bound_modulo_regions
  13:     0x7ffef1039b34 - rustc_ty_utils[91a0d221f715ed1d]::provide
  14:     0x7ffef103f635 - rustc_ty_utils[91a0d221f715ed1d]::provide
  15:     0x7ffef19b54af - <rustc_middle[5a9507fdf2b1653f]::mir::ProjectionElem<rustc_middle[5a9507fdf2b1653f]::mir::Local, rustc_middle[5a9507fdf2b1653f]::ty::Ty> as rustc_mir_dataflow[360290be34aeb823]::move_paths::abs_domain::Lift>::lift
  16:     0x7ffef1ae1cb7 - <rustc_middle[5a9507fdf2b1653f]::mir::ProjectionElem<rustc_middle[5a9507fdf2b1653f]::mir::Local, rustc_middle[5a9507fdf2b1653f]::ty::Ty> as rustc_mir_dataflow[360290be34aeb823]::move_paths::abs_domain::Lift>::lift
  17:     0x7ffef29ddc37 - <rustc_middle[5a9507fdf2b1653f]::ty::Ty>::is_sized
  18:     0x7ffef290db7a - <rustc_middle[5a9507fdf2b1653f]::ty::layout::LayoutError as core[6a08d9f219683c56]::fmt::Display>::fmt
  19:     0x7ffef2928c19 - <rustc_middle[5a9507fdf2b1653f]::ty::layout::LayoutError as core[6a08d9f219683c56]::fmt::Debug>::fmt
  20:     0x7ffef1b23feb - <rustc_middle[5a9507fdf2b1653f]::mir::ProjectionElem<rustc_middle[5a9507fdf2b1653f]::mir::Local, rustc_middle[5a9507fdf2b1653f]::ty::Ty> as rustc_mir_dataflow[360290be34aeb823]::move_paths::abs_domain::Lift>::lift
  21:     0x7ffef1d3b587 - <rustc_query_impl[9aae81924dcd9b86]::Queries as rustc_middle[5a9507fdf2b1653f]::ty::query::QueryEngine>::try_mark_green
  22:     0x7ffef2962af3 - <rustc_target[5315af22f2d07e61]::abi::Integer as rustc_middle[5a9507fdf2b1653f]::ty::layout::IntegerExt>::repr_discr
  23:     0x7ffef2951143 - <rustc_middle[5a9507fdf2b1653f]::ty::relate::GeneratorWitness as core[6a08d9f219683c56]::fmt::Debug>::fmt
  24:     0x7ffef2950505 - <rustc_middle[5a9507fdf2b1653f]::ty::relate::GeneratorWitness as core[6a08d9f219683c56]::fmt::Debug>::fmt
  25:     0x7ffef290ddf2 - <rustc_middle[5a9507fdf2b1653f]::ty::layout::LayoutError as core[6a08d9f219683c56]::fmt::Display>::fmt
  26:     0x7ffef2928c19 - <rustc_middle[5a9507fdf2b1653f]::ty::layout::LayoutError as core[6a08d9f219683c56]::fmt::Debug>::fmt
  27:     0x7ffef1b23feb - <rustc_middle[5a9507fdf2b1653f]::mir::ProjectionElem<rustc_middle[5a9507fdf2b1653f]::mir::Local, rustc_middle[5a9507fdf2b1653f]::ty::Ty> as rustc_mir_dataflow[360290be34aeb823]::move_paths::abs_domain::Lift>::lift
  28:     0x7ffef1d3b587 - <rustc_query_impl[9aae81924dcd9b86]::Queries as rustc_middle[5a9507fdf2b1653f]::ty::query::QueryEngine>::try_mark_green
  29:     0x7ffef2962af3 - <rustc_target[5315af22f2d07e61]::abi::Integer as rustc_middle[5a9507fdf2b1653f]::ty::layout::IntegerExt>::repr_discr
  30:     0x7ffef2951143 - <rustc_middle[5a9507fdf2b1653f]::ty::relate::GeneratorWitness as core[6a08d9f219683c56]::fmt::Debug>::fmt
  31:     0x7ffef2950505 - <rustc_middle[5a9507fdf2b1653f]::ty::relate::GeneratorWitness as core[6a08d9f219683c56]::fmt::Debug>::fmt
  32:     0x7ffef290ddf2 - <rustc_middle[5a9507fdf2b1653f]::ty::layout::LayoutError as core[6a08d9f219683c56]::fmt::Display>::fmt
  33:     0x7ffef2928c19 - <rustc_middle[5a9507fdf2b1653f]::ty::layout::LayoutError as core[6a08d9f219683c56]::fmt::Debug>::fmt
  34:     0x7ffef1b23feb - <rustc_middle[5a9507fdf2b1653f]::mir::ProjectionElem<rustc_middle[5a9507fdf2b1653f]::mir::Local, rustc_middle[5a9507fdf2b1653f]::ty::Ty> as rustc_mir_dataflow[360290be34aeb823]::move_paths::abs_domain::Lift>::lift
  35:     0x7ffef1d3b587 - <rustc_query_impl[9aae81924dcd9b86]::Queries as rustc_middle[5a9507fdf2b1653f]::ty::query::QueryEngine>::try_mark_green
  36:     0x7ffef1d99a0f - rustc_codegen_ssa[d885ec56d44a02af]::debuginfo::type_names::compute_debuginfo_type_name
  37:     0x7ffef1d9b818 - rustc_codegen_ssa[d885ec56d44a02af]::debuginfo::type_names::compute_debuginfo_type_name
  38:     0x7ffef1d98bfd - rustc_codegen_ssa[d885ec56d44a02af]::debuginfo::type_names::compute_debuginfo_type_name
  39:     0x7ffeee5b96f5 - <rustc_type_ir[58c157682bebb2ff]::FloatTy as rustc_codegen_llvm[c0bf652cb963b7b7]::debuginfo::metadata::MsvcBasicName>::msvc_basic_name
  40:     0x7ffeee5b9c23 - <rustc_type_ir[58c157682bebb2ff]::FloatTy as rustc_codegen_llvm[c0bf652cb963b7b7]::debuginfo::metadata::MsvcBasicName>::msvc_basic_name
  41:     0x7ffeee5b937b - <rustc_type_ir[58c157682bebb2ff]::FloatTy as rustc_codegen_llvm[c0bf652cb963b7b7]::debuginfo::metadata::MsvcBasicName>::msvc_basic_name
  42:     0x7ffeee5b9cd6 - <rustc_type_ir[58c157682bebb2ff]::FloatTy as rustc_codegen_llvm[c0bf652cb963b7b7]::debuginfo::metadata::MsvcBasicName>::msvc_basic_name
  43:     0x7ffeee5b0f5d - <rustc_type_ir[58c157682bebb2ff]::FloatTy as rustc_codegen_llvm[c0bf652cb963b7b7]::debuginfo::metadata::MsvcBasicName>::msvc_basic_name
  44:     0x7ffeee5e5533 - <rustc_codegen_llvm[c0bf652cb963b7b7]::debuginfo::utils::FatPtrKind as core[6a08d9f219683c56]::fmt::Debug>::fmt
  45:     0x7ffeee4a4763 - <rustc_codegen_llvm[c0bf652cb963b7b7]::builder::Builder as core[6a08d9f219683c56]::ops::drop::Drop>::drop
  46:     0x7ffeee5bc650 - <rustc_type_ir[58c157682bebb2ff]::FloatTy as rustc_codegen_llvm[c0bf652cb963b7b7]::debuginfo::metadata::MsvcBasicName>::msvc_basic_name
  47:     0x7ffeee5b9fa1 - <rustc_type_ir[58c157682bebb2ff]::FloatTy as rustc_codegen_llvm[c0bf652cb963b7b7]::debuginfo::metadata::MsvcBasicName>::msvc_basic_name
  48:     0x7ffeee5b937b - <rustc_type_ir[58c157682bebb2ff]::FloatTy as rustc_codegen_llvm[c0bf652cb963b7b7]::debuginfo::metadata::MsvcBasicName>::msvc_basic_name
  49:     0x7ffeee5b9b55 - <rustc_type_ir[58c157682bebb2ff]::FloatTy as rustc_codegen_llvm[c0bf652cb963b7b7]::debuginfo::metadata::MsvcBasicName>::msvc_basic_name
  50:     0x7ffeee497074 - <rustc_codegen_llvm[c0bf652cb963b7b7]::builder::Builder as core[6a08d9f219683c56]::ops::drop::Drop>::drop
  51:     0x7ffeee570d5e - <rustc_codegen_llvm[c0bf652cb963b7b7]::debuginfo::CodegenUnitDebugContext as core[6a08d9f219683c56]::ops::drop::Drop>::drop
  52:     0x7ffeee54b0bf - <rustc_codegen_llvm[c0bf652cb963b7b7]::context::CodegenCx as rustc_codegen_ssa[d885ec56d44a02af]::traits::debuginfo::DebugInfoMethods>::dbg_scope_fn
  53:     0x7ffeee54ac4f - <rustc_codegen_llvm[c0bf652cb963b7b7]::context::CodegenCx as rustc_codegen_ssa[d885ec56d44a02af]::traits::debuginfo::DebugInfoMethods>::create_function_debug_context
  54:     0x7ffeee5c2ed3 - <rustc_codegen_llvm[c0bf652cb963b7b7]::debuginfo::utils::FatPtrKind as core[6a08d9f219683c56]::fmt::Debug>::fmt
  55:     0x7ffeee490d32 - <rustc_codegen_llvm[c0bf652cb963b7b7]::builder::Builder as core[6a08d9f219683c56]::ops::drop::Drop>::drop
  56:     0x7ffeee59633c - <rustc_type_ir[58c157682bebb2ff]::FloatTy as rustc_codegen_llvm[c0bf652cb963b7b7]::debuginfo::metadata::MsvcBasicName>::msvc_basic_name
  57:     0x7ffeee4db7e1 - <rustc_codegen_llvm[c0bf652cb963b7b7]::base::ValueIter as core[6a08d9f219683c56]::iter::traits::iterator::Iterator>::next
  58:     0x7ffeee5256b1 - <rustc_codegen_llvm[c0bf652cb963b7b7]::llvm_::archive_ro::Child as core[6a08d9f219683c56]::ops::drop::Drop>::drop
  59:     0x7ffeee4db0a0 - <rustc_codegen_llvm[c0bf652cb963b7b7]::base::ValueIter as core[6a08d9f219683c56]::iter::traits::iterator::Iterator>::next
  60:     0x7ffeee48f8e9 - <rustc_codegen_llvm[c0bf652cb963b7b7]::builder::Builder as core[6a08d9f219683c56]::ops::drop::Drop>::drop
  61:     0x7ffeee554d15 - <rustc_codegen_llvm[c0bf652cb963b7b7]::LlvmCodegenBackend as rustc_codegen_ssa[d885ec56d44a02af]::traits::backend::CodegenBackend>::codegen_crate
  62:     0x7ffeee45d992 - <rustc_interface[cf6410c125894462]::passes::boxed_resolver::BoxedResolver>::to_resolver_outputs
  63:     0x7ffeee406d9d - <rustc_interface[cf6410c125894462]::passes::LintStoreExpandImpl as rustc_expand[9134cab9b4f9f9fa]::base::LintStoreExpand>::pre_expansion_lint
  64:     0x7ffeee3e6b50 - <rustc_interface[cf6410c125894462]::queries::Queries>::ongoing_codegen
  65:     0x7ffeee2458e7 - <tracing_subscriber[2e748d7cd1882154]::fmt::writer::TestWriter as tracing_subscriber[2e748d7cd1882154]::fmt::writer::MakeWriter>::make_writer
  66:     0x7ffeee272685 - <rustc_middle[5a9507fdf2b1653f]::ty::SymbolName as core[6a08d9f219683c56]::fmt::Debug>::fmt
  67:     0x7ffeee246d96 - <tracing_subscriber[2e748d7cd1882154]::fmt::writer::TestWriter as tracing_subscriber[2e748d7cd1882154]::fmt::writer::MakeWriter>::make_writer
  68:     0x7ffeee23a4c6 - <tracing_subscriber[2e748d7cd1882154]::fmt::writer::TestWriter as tracing_subscriber[2e748d7cd1882154]::fmt::writer::MakeWriter>::make_writer
  69:     0x7ffeee279b13 - <rustc_middle[5a9507fdf2b1653f]::ty::SymbolName as core[6a08d9f219683c56]::fmt::Debug>::fmt
  70:     0x7fff433aca2c - std::sys::windows::thread::Thread::new::h1c645754750a6abb
  71:     0x7fff839a7034 - BaseThreadInitThunk
  72:     0x7fff85742651 - RtlUserThreadStart

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.61.0-nightly (461e80780 2022-03-16) running on x86_64-pc-windows-msvc

note: compiler flags: --crate-type lib -C embed-bitcode=no -C debuginfo=2

note: some of the compiler flags provided by cargo are hidden

query stack during panic:
#0 [is_sized_raw] computing whether `dyn std::io::Write` is `Sized`
#1 [layout_of] computing layout of `*const dyn std::io::Write`
#2 [layout_of] computing layout of `core::ptr::unique::Unique<dyn std::io::Write>`
#3 [layout_of] computing layout of `alloc::boxed::Box<dyn std::io::Write>`
end of query stack
error: could not compile `tracing-subscriber`
warning: build failed, waiting for other jobs to finish...
error: build failed
@Dentosal Dentosal 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 Mar 18, 2022
@compiler-errors
Copy link
Member

This will be fixed on the next nightly, cc #95020

@jackh726
Copy link
Member

Closing as duplicate of #94998

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. 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.
Projects
None yet
Development

No branches or pull requests

3 participants