Skip to content

[Internal Compiler Error] occurred when compiling eww with latest nightly build (2022-01-21) #93197

Description

@Animeshz

Builds fails only with the latest (yesterday released) rustc 1.60.0-nightly (17d29dcdc 2022-01-21) running on x86_64-unknown-linux-gnu compiler. Tested with 2022-01-20 compiler and it works all okay!

Code

For now: refer to elkowar/eww:crates/eww/src/script_var_handler.rs#L137. I'll update if I'm able to minimize where actually the rustc panics.

<code>

Meta

rustc --version --verbose:

rustc 1.60.0-nightly (17d29dcdc 2022-01-21)
binary: rustc
commit-hash: 17d29dcdce9b9e838635eb0adefd9b8b1588410b
commit-date: 2022-01-21
host: x86_64-unknown-linux-gnu
release: 1.60.0-nightly
LLVM version: 13.0.0

Error output

  eww on  master [✘] via  via 🦀 v1.60.0-nightly >>> cargo build --release
    ...
   Compiling gdk-pixbuf v0.14.0
   Compiling gdk v0.14.3
warning: the feature `format_args_capture` has been stable since 1.58.0 and no longer requires an attribute to enable
 --> crates/simplexpr/src/lib.rs:2:12
  |
2 | #![feature(format_args_capture)]
  |            ^^^^^^^^^^^^^^^^^^^
  |
  = note: `#[warn(stable_features)]` on by default

   Compiling gdkx11 v0.14.0
warning: `simplexpr` (lib) generated 1 warning
    Building [=======================> ] 364/366: gtk                                                                                                      Bu   Compiling eww v0.2.0 (/home/animesh/Projects/RustProjects/eww/crates/eww)
thread 'rustc' panicked at 'Expression ID not found', compiler/rustc_typeck/src/check/generator_interior/drop_ranges/cfg_build.rs:468:52
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.60.0-nightly (17d29dcdc 2022-01-21) running on x86_64-unknown-linux-gnu

note: compiler flags: -C opt-level=3 -C embed-bitcode=no --crate-type bin

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

query stack during panic:
#0 [typeck] type-checking `script_var_handler::<impl at crates/eww/src/script_var_handler.rs:131:1: 179:2>::start`
#1 [mir_built] building MIR for `script_var_handler::<impl at crates/eww/src/script_var_handler.rs:131:1: 179:2>::start`
end of query stack
error: could not compile `eww`
Backtrace

  eww on  master [✘] via  via 🦀 v1.60.0-nightly took 2m15s ✗✗✗ RUST_BACKTRACE=1 cargo build --release
warning: /home/animesh/Projects/RustProjects/eww/crates/eww/Cargo.toml: the cargo feature `edition2021` has been stabilized in the 1.56 release and is no longer necessary to be listed in the manifest
  See https://doc.rust-lang.org/nightly/cargo/reference/manifest.html#the-edition-field for more information about using this feature.
warning: the feature `format_args_capture` has been stable since 1.58.0 and no longer requires an attribute to enable
 --> crates/simplexpr/src/lib.rs:2:12
  |
2 | #![feature(format_args_capture)]
  |            ^^^^^^^^^^^^^^^^^^^
  |
  = note: `#[warn(stable_features)]` on by default

warning: `simplexpr` (lib) generated 1 warning
   Compiling eww v0.2.0 (/home/animesh/Projects/RustProjects/eww/crates/eww)
thread 'rustc' panicked at 'Expression ID not found', compiler/rustc_typeck/src/check/generator_interior/drop_ranges/cfg_build.rs:468:52
stack backtrace:
   0: rust_begin_unwind
             at /rustc/17d29dcdce9b9e838635eb0adefd9b8b1588410b/library/std/src/panicking.rs:577:5
   1: core::panicking::panic_fmt
             at /rustc/17d29dcdce9b9e838635eb0adefd9b8b1588410b/library/core/src/panicking.rs:110:14
   2: core::panicking::panic_display
             at /rustc/17d29dcdce9b9e838635eb0adefd9b8b1588410b/library/core/src/panicking.rs:65:5
   3: core::panicking::panic_str
             at /rustc/17d29dcdce9b9e838635eb0adefd9b8b1588410b/library/core/src/panicking.rs:56:5
   4: core::option::expect_failed
             at /rustc/17d29dcdce9b9e838635eb0adefd9b8b1588410b/library/core/src/option.rs:1840:5
   5: <rustc_typeck::check::generator_interior::drop_ranges::DropRangesBuilder>::process_deferred_edges
   6: rustc_typeck::check::generator_interior::drop_ranges::cfg_build::build_control_flow_graph
   7: rustc_typeck::check::generator_interior::drop_ranges::compute_drop_ranges
   8: rustc_typeck::check::generator_interior::resolve_interior
   9: <rustc_infer::infer::InferCtxtBuilder>::enter::<&rustc_middle::ty::context::TypeckResults, <rustc_typeck::check::inherited::InheritedBuilder>::enter<rustc_typeck::check::typeck_with_fallback<rustc_typeck::check::typeck::{closure#0}>::{closure#1}, &rustc_middle::ty::context::TypeckResults>::{closure#0}>
  10: rustc_typeck::check::typeck
  11: rustc_query_system::query::plumbing::try_execute_query::<rustc_query_impl::plumbing::QueryCtxt, rustc_query_system::query::caches::DefaultCache<rustc_span::def_id::LocalDefId, &rustc_middle::ty::context::TypeckResults>>
  12: <rustc_query_impl::Queries as rustc_middle::ty::query::QueryEngine>::typeck
  13: <rustc_middle::ty::context::TyCtxt>::typeck_opt_const_arg
  14: rustc_mir_build::build::mir_built
  15: rustc_query_system::query::plumbing::try_execute_query::<rustc_query_impl::plumbing::QueryCtxt, rustc_query_system::query::caches::DefaultCache<rustc_middle::ty::WithOptConstParam<rustc_span::def_id::LocalDefId>, &rustc_data_structures::steal::Steal<rustc_middle::mir::Body>>>
  16: <rustc_query_impl::Queries as rustc_middle::ty::query::QueryEngine>::mir_built
  17: rustc_mir_transform::check_unsafety::unsafety_check_result
  18: <rustc_mir_transform::check_unsafety::provide::{closure#0} as core::ops::function::FnOnce<(rustc_middle::ty::context::TyCtxt, rustc_span::def_id::LocalDefId)>>::call_once
  19: rustc_query_system::query::plumbing::try_execute_query::<rustc_query_impl::plumbing::QueryCtxt, rustc_query_system::query::caches::DefaultCache<rustc_span::def_id::LocalDefId, &rustc_middle::mir::query::UnsafetyCheckResult>>
  20: <rustc_query_impl::Queries as rustc_middle::ty::query::QueryEngine>::unsafety_check_result
  21: rustc_mir_transform::mir_const
  22: rustc_query_system::query::plumbing::try_execute_query::<rustc_query_impl::plumbing::QueryCtxt, rustc_query_system::query::caches::DefaultCache<rustc_middle::ty::WithOptConstParam<rustc_span::def_id::LocalDefId>, &rustc_data_structures::steal::Steal<rustc_middle::mir::Body>>>
  23: <rustc_query_impl::Queries as rustc_middle::ty::query::QueryEngine>::mir_const
  24: rustc_mir_transform::mir_promoted
  25: rustc_query_system::query::plumbing::try_execute_query::<rustc_query_impl::plumbing::QueryCtxt, rustc_query_system::query::caches::DefaultCache<rustc_middle::ty::WithOptConstParam<rustc_span::def_id::LocalDefId>, (&rustc_data_structures::steal::Steal<rustc_middle::mir::Body>, &rustc_data_structures::steal::Steal<rustc_index::vec::IndexVec<rustc_middle::mir::Promoted, rustc_middle::mir::Body>>)>>
  26: <rustc_query_impl::Queries as rustc_middle::ty::query::QueryEngine>::mir_promoted
  27: <rustc_borrowck::provide::{closure#0} as core::ops::function::FnOnce<(rustc_middle::ty::context::TyCtxt, rustc_span::def_id::LocalDefId)>>::call_once
  28: rustc_query_system::query::plumbing::try_execute_query::<rustc_query_impl::plumbing::QueryCtxt, rustc_query_system::query::caches::DefaultCache<rustc_span::def_id::LocalDefId, &rustc_middle::mir::query::BorrowCheckResult>>
  29: <rustc_query_impl::Queries as rustc_middle::ty::query::QueryEngine>::mir_borrowck
  30: rustc_typeck::collect::type_of::type_of
  31: <rustc_query_impl::Queries as rustc_middle::ty::query::QueryEngine>::type_of
  32: <rustc_middle::ty::util::OpaqueTypeExpander>::expand_opaque_ty
  33: <&rustc_middle::ty::TyS as rustc_middle::ty::fold::TypeFoldable>::try_fold_with::<rustc_middle::ty::util::OpaqueTypeExpander>
  34: rustc_middle::ty::util::fold_list::<rustc_middle::ty::util::OpaqueTypeExpander, &rustc_middle::ty::TyS, <&rustc_middle::ty::list::List<&rustc_middle::ty::TyS> as rustc_middle::ty::fold::TypeFoldable>::try_super_fold_with<rustc_middle::ty::util::OpaqueTypeExpander>::{closure#0}>
  35: <rustc_middle::ty::util::OpaqueTypeExpander as rustc_middle::ty::fold::FallibleTypeFolder>::try_fold_binder::<&rustc_middle::ty::list::List<&rustc_middle::ty::TyS>>
  36: <&rustc_middle::ty::TyS as rustc_middle::ty::fold::TypeFoldable>::super_fold_with::<rustc_middle::ty::util::OpaqueTypeExpander>
  37: <smallvec::SmallVec<[rustc_middle::ty::subst::GenericArg; 8]> as core::iter::traits::collect::Extend<rustc_middle::ty::subst::GenericArg>>::extend::<core::iter::adapters::ResultShunt<core::iter::adapters::map::Map<core::iter::adapters::copied::Copied<core::slice::iter::Iter<rustc_middle::ty::subst::GenericArg>>, <&rustc_middle::ty::list::List<rustc_middle::ty::subst::GenericArg> as rustc_middle::ty::fold::TypeFoldable>::try_super_fold_with<rustc_middle::ty::util::OpaqueTypeExpander>::{closure#0}>, !>>
  38: <&rustc_middle::ty::list::List<rustc_middle::ty::subst::GenericArg> as rustc_middle::ty::fold::TypeFoldable>::try_fold_with::<rustc_middle::ty::util::OpaqueTypeExpander>
  39: <&rustc_middle::ty::TyS as rustc_middle::ty::fold::TypeFoldable>::super_fold_with::<rustc_middle::ty::util::OpaqueTypeExpander>
  40: <&rustc_middle::ty::list::List<rustc_middle::ty::subst::GenericArg> as rustc_middle::ty::fold::TypeFoldable>::try_fold_with::<rustc_middle::ty::util::OpaqueTypeExpander>
  41: <rustc_middle::ty::util::OpaqueTypeExpander>::expand_opaque_ty
  42: <rustc_middle::ty::util::OpaqueTypeExpander>::expand_opaque_ty
  43: <rustc_middle::ty::context::TyCtxt>::try_expand_impl_trait_type
  44: rustc_typeck::check::check::check_item_type
  45: <rustc_middle::hir::map::Map>::visit_item_likes_in_module::<rustc_typeck::check::CheckItemTypesVisitor>
  46: rustc_typeck::check::check::check_mod_item_types
  47: rustc_query_system::query::plumbing::try_execute_query::<rustc_query_impl::plumbing::QueryCtxt, rustc_query_system::query::caches::DefaultCache<rustc_span::def_id::LocalDefId, ()>>
  48: rustc_query_system::query::plumbing::get_query::<rustc_query_impl::queries::check_mod_item_types, rustc_query_impl::plumbing::QueryCtxt>
  49: <rustc_middle::hir::map::Map>::for_each_module::<rustc_typeck::check_crate::{closure#6}::{closure#0}>
  50: <rustc_session::session::Session>::time::<(), rustc_typeck::check_crate::{closure#6}>
  51: rustc_typeck::check_crate
  52: rustc_interface::passes::analysis
  53: rustc_query_system::query::plumbing::try_execute_query::<rustc_query_impl::plumbing::QueryCtxt, rustc_query_system::query::caches::DefaultCache<(), core::result::Result<(), rustc_errors::ErrorReported>>>
  54: rustc_query_system::query::plumbing::get_query::<rustc_query_impl::queries::analysis, rustc_query_impl::plumbing::QueryCtxt>
  55: <rustc_interface::passes::QueryContext>::enter::<rustc_driver::run_compiler::{closure#1}::{closure#2}::{closure#3}, core::result::Result<(), rustc_errors::ErrorReported>>
  56: <rustc_interface::interface::Compiler>::enter::<rustc_driver::run_compiler::{closure#1}::{closure#2}, core::result::Result<core::option::Option<rustc_interface::queries::Linker>, rustc_errors::ErrorReported>>
  57: rustc_span::with_source_map::<core::result::Result<(), rustc_errors::ErrorReported>, rustc_interface::interface::create_compiler_and_run<core::result::Result<(), rustc_errors::ErrorReported>, rustc_driver::run_compiler::{closure#1}>::{closure#1}>
  58: <scoped_tls::ScopedKey<rustc_span::SessionGlobals>>::set::<rustc_interface::util::setup_callbacks_and_run_in_thread_pool_with_globals<rustc_interface::interface::run_compiler<core::result::Result<(), rustc_errors::ErrorReported>, rustc_driver::run_compiler::{closure#1}>::{closure#0}, core::result::Result<(), rustc_errors::ErrorReported>>::{closure#0}::{closure#0}, core::result::Result<(), rustc_errors::ErrorReported>>
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.60.0-nightly (17d29dcdc 2022-01-21) running on x86_64-unknown-linux-gnu

note: compiler flags: -C opt-level=3 -C embed-bitcode=no --crate-type bin

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

query stack during panic:
#0 [typeck] type-checking `script_var_handler::<impl at crates/eww/src/script_var_handler.rs:131:1: 179:2>::start`
#1 [mir_built] building MIR for `script_var_handler::<impl at crates/eww/src/script_var_handler.rs:131:1: 179:2>::start`
#2 [unsafety_check_result] unsafety-checking `script_var_handler::<impl at crates/eww/src/script_var_handler.rs:131:1: 179:2>::start`
#3 [mir_const] processing MIR for `script_var_handler::<impl at crates/eww/src/script_var_handler.rs:131:1: 179:2>::start`
#4 [mir_promoted] processing `script_var_handler::<impl at crates/eww/src/script_var_handler.rs:131:1: 179:2>::start`
#5 [mir_borrowck] borrow-checking `script_var_handler::<impl at crates/eww/src/script_var_handler.rs:131:1: 179:2>::start`
#6 [type_of] computing type of `script_var_handler::<impl at crates/eww/src/script_var_handler.rs:131:1: 179:2>::start::{opaque#0}`
#7 [check_mod_item_types] checking item types in module `script_var_handler`
#8 [analysis] running analysis passes on this crate
end of query stack
error: could not compile `eww`

No activity

Activity on this issue will appear here.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

C-bugCategory: This is a bug.E-needs-mcveCall for participation: This issue has a repro, but needs a Minimal Complete and Verifiable ExampleI-ICEIssue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions