Skip to content

ICE during clippy #7927

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

Closed
gzp79 opened this issue Nov 4, 2021 · 2 comments
Closed

ICE during clippy #7927

gzp79 opened this issue Nov 4, 2021 · 2 comments
Labels
I-ICE Issue: Clippy panicked, giving an Internal Compilation Error (ICE) ❄️

Comments

@gzp79
Copy link

gzp79 commented Nov 4, 2021

I'm not sure what modification I had in the code, but compiler failed win an internal error (see below), but after a cargo clean all was working again.

(I don't know if it is relevant but my modification before the failure were marking a trait (and it's implementation) unsafe related and adding a few panic related comments.)

thread 'rustc' panicked at 'called `Option::unwrap()` on a `None` value', /rustc/e99963c554e4d12010c2dea9f46d7bbd41dc1271\compiler\rustc_hir\src\definitions.rs:452:14
stack backtrace:
   0:     0x7ff8a6338b4f - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::h4287336b592e4e30
   1:     0x7ff8a63627ca - core::fmt::write::h8a2c40ddb66ccc71
   2:     0x7ff8a632b4f8 - <std::io::IoSlice as core::fmt::Debug>::fmt::h37489b9473b33977
   3:     0x7ff8a633c2a6 - std::panicking::take_hook::hf14c76592f73c762
   4:     0x7ff8a633bd8c - std::panicking::take_hook::hf14c76592f73c762
   5:     0x7ff6bab7c28e - <unknown>
   6:     0x7ff8a633cbb9 - std::panicking::rust_panic_with_hook::hbc0e9c80ca88eac0
   7:     0x7ff8a633c62f - rust_begin_unwind
   8:     0x7ff8a6339487 - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::h4287336b592e4e30
   9:     0x7ff8a633c5b9 - rust_begin_unwind
  10:     0x7ff8a6396cd0 - core::panicking::panic_fmt::hc1b1ca620e7a2c9f
  11:     0x7ff8a6396c1c - core::panicking::panic::hfef5cee9afdef02a
  12:     0x7ff8816e514a - <rustc_middle[68438b5bfe988d4e]::ty::context::TyCtxt>::def_path_hash_to_def_id
  13:     0x7ff8817df46e - <rustc_query_system[993d4a9a8633e257]::dep_graph::dep_node::DepNode<rustc_middle[68438b5bfe988d4e]::dep_graph::dep_node::DepKind> as rustc_middle[68438b5bfe988d4e]::dep_graph::dep_node::DepNodeExt>::extract_def_id
  14:     0x7ff8809d0ad4 - rustc_query_impl[2492acdb0e5eb4f6]::query_callbacks::hir_owner
  15:     0x7ff8816cc0b3 - <rustc_middle[68438b5bfe988d4e]::ty::context::TyCtxt as rustc_query_system[993d4a9a8633e257]::dep_graph::DepContext>::try_force_from_dep_node
  16:     0x7ff880a247cb - <rustc_query_impl[2492acdb0e5eb4f6]::Queries as rustc_middle[68438b5bfe988d4e]::ty::query::QueryEngine>::try_mark_green        
  17:     0x7ff880a247a7 - <rustc_query_impl[2492acdb0e5eb4f6]::Queries as rustc_middle[68438b5bfe988d4e]::ty::query::QueryEngine>::try_mark_green        
  18:     0x7ff880a247a7 - <rustc_query_impl[2492acdb0e5eb4f6]::Queries as rustc_middle[68438b5bfe988d4e]::ty::query::QueryEngine>::try_mark_green        
  19:     0x7ff880a247a7 - <rustc_query_impl[2492acdb0e5eb4f6]::Queries as rustc_middle[68438b5bfe988d4e]::ty::query::QueryEngine>::try_mark_green        
  20:     0x7ff880a247a7 - <rustc_query_impl[2492acdb0e5eb4f6]::Queries as rustc_middle[68438b5bfe988d4e]::ty::query::QueryEngine>::try_mark_green        
  21:     0x7ff880a247a7 - <rustc_query_impl[2492acdb0e5eb4f6]::Queries as rustc_middle[68438b5bfe988d4e]::ty::query::QueryEngine>::try_mark_green        
  22:     0x7ff8809fcaea - <rustc_query_impl[2492acdb0e5eb4f6]::Queries as rustc_middle[68438b5bfe988d4e]::ty::query::QueryEngine>::try_mark_green        
  23:     0x7ff88073197c - <rustc_mir_dataflow[b218101e43c2c97d]::framework::cursor::CursorPosition as core[3b5640218fb446b]::fmt::Debug>::fmt
  24:     0x7ff8808a1cf2 - <rustc_mir_dataflow[b218101e43c2c97d]::framework::cursor::CursorPosition as core[3b5640218fb446b]::fmt::Debug>::fmt
  25:     0x7ff87d42c5eb - <rustc_interface[ff1d7c07a753e82f]::passes::boxed_resolver::BoxedResolver>::to_resolver_outputs
  26:     0x7ff87d44e0b3 - <rustc_interface[ff1d7c07a753e82f]::passes::boxed_resolver::BoxedResolver>::to_resolver_outputs
  27:     0x7ff87d394098 - rustc_interface[ff1d7c07a753e82f]::passes::analysis
  28:     0x7ff880abeb5b - <rustc_query_impl[2492acdb0e5eb4f6]::on_disk_cache::CacheDecoder as rustc_serialize[e9f3e8e17ec8afb5]::serialize::Decoder>::error
  29:     0x7ff880a5813e - <rustc_query_impl[2492acdb0e5eb4f6]::Queries as rustc_middle[68438b5bfe988d4e]::ty::query::QueryEngine>::try_mark_green        
  30:     0x7ff88098de61 - rustc_query_impl[2492acdb0e5eb4f6]::profiling_support::alloc_self_profile_query_strings
  31:     0x7ff880819179 - <rustc_mir_dataflow[b218101e43c2c97d]::framework::cursor::CursorPosition as core[3b5640218fb446b]::fmt::Debug>::fmt
  32:     0x7ff8808e11a2 - <rustc_mir_dataflow[b218101e43c2c97d]::framework::cursor::CursorPosition as core[3b5640218fb446b]::fmt::Debug>::fmt
  33:     0x7ff87d289e2a - <rustc_span[abfcba77a0dab5e7]::symbol::SymbolStr as core[3b5640218fb446b]::fmt::Display>::fmt
  34:     0x7ff87d28a8cb - <rustc_span[abfcba77a0dab5e7]::symbol::SymbolStr as core[3b5640218fb446b]::fmt::Display>::fmt
  35:     0x7ff87d244816 - rustc_driver[af3c8dcfa508860b]::pretty::print_after_hir_lowering
  36:     0x7ff87d2a6bd6 - <rustc_span[abfcba77a0dab5e7]::symbol::SymbolStr as core[3b5640218fb446b]::fmt::Display>::fmt
  37:     0x7ff87d24dd13 - rustc_driver[af3c8dcfa508860b]::pretty::print_after_hir_lowering
  38:     0x7ff87d2c5788 - <rustc_driver[af3c8dcfa508860b]::args::Error as core[3b5640218fb446b]::fmt::Debug>::fmt
  39:     0x7ff8a634927c - std::sys::windows::thread::Thread::new::he49a5cdb1d3d1cfc
  40:     0x7ff901197034 - BaseThreadInitThunk
  41:     0x7ff902ea2651 - 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-clippy/issues/new

note: Clippy version: clippy 0.1.58 (e99963c5 2021-10-29)

query stack during panic:
#0 [analysis] running analysis passes on this crate
end of query stack
@giraffate
Copy link
Contributor

This seems to be a rustc issue, not clippy, and be related to rust-lang/rust#89962.

@giraffate giraffate added the I-ICE Issue: Clippy panicked, giving an Internal Compilation Error (ICE) ❄️ label Nov 4, 2021
@giraffate
Copy link
Contributor

It seems to be rustc issue, so I'm closing this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
I-ICE Issue: Clippy panicked, giving an Internal Compilation Error (ICE) ❄️
Projects
None yet
Development

No branches or pull requests

2 participants