Skip to content
This repository was archived by the owner on Dec 29, 2022. It is now read-only.

ICE during initial analysis #558

Closed
sfackler opened this issue Nov 7, 2017 · 3 comments
Closed

ICE during initial analysis #558

sfackler opened this issue Nov 7, 2017 · 3 comments
Labels

Comments

@sfackler
Copy link
Member

sfackler commented Nov 7, 2017

This is on a large repository in workspace mode, using rls master.

    Finished release [optimized] target(s) in 0.0 secs
     Running `target/release/rls`
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/blob/master/CONTRIBUTING.md#bug-reports

note: rustc 1.23.0-nightly (3b82e4c74 2017-11-05) running on x86_64-apple-darwin

note: run with `RUST_BACKTRACE=1` for a backtrace

thread 'rustc' panicked at 'LocalTableInContext: key not found', src/libcore/option.rs:839:4
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
stack backtrace:
   0: std::sys::imp::backtrace::tracing::imp::unwind_backtrace
   1: std::sys_common::backtrace::_print
   2: std::panicking::default_hook::{{closure}}
   3: std::panicking::default_hook
   4: std::panicking::rust_panic_with_hook
   5: std::panicking::begin_panic
   6: std::panicking::begin_panic_fmt
   7: rust_begin_unwind
   8: core::panicking::panic_fmt
   9: core::option::expect_failed
  10: <rustc::ty::context::LocalTableInContext<'a, V> as core::ops::index::Index<rustc::hir::HirId>>::index
  11: rustc_save_analysis::SaveContext::get_expr_data
  12: _ZN109_$LT$rustc_save_analysis..dump_visitor..DumpVisitor$LT$$u27$l$C$$u20$$u27$tcx$C$$u20$$u27$ll$C$$u20$O$GT$$GT$19process_method_call17hecabccc66923046aE.llvm.5EA9DA55
  13: syntax::visit::walk_expr
  14: <rustc_save_analysis::dump_visitor::DumpVisitor<'l, 'tcx, 'll, O> as syntax::visit::Visitor<'l>>::visit_arm
  15: syntax::visit::walk_expr
  16: _ZN109_$LT$rustc_save_analysis..dump_visitor..DumpVisitor$LT$$u27$l$C$$u20$$u27$tcx$C$$u20$$u27$ll$C$$u20$O$GT$$GT$14process_method17h291dca7812304c53E.llvm.5EA9DA55
  17: <rustc_save_analysis::dump_visitor::DumpVisitor<'l, 'tcx, 'll, O> as syntax::visit::Visitor<'l>>::visit_item
  18: <rustc_save_analysis::dump_visitor::DumpVisitor<'l, 'tcx, 'll, O> as syntax::visit::Visitor<'l>>::visit_item
  19: <rustc_save_analysis::dump_visitor::DumpVisitor<'l, 'tcx, 'll, O> as syntax::visit::Visitor<'l>>::visit_item
  20: <rustc_save_analysis::dump_visitor::DumpVisitor<'l, 'tcx, 'll, O> as syntax::visit::Visitor<'l>>::visit_mod
  21: <rustc_save_analysis::CallbackHandler<'b> as rustc_save_analysis::SaveHandler>::save
  22: <rls::build::rustc::RlsRustcCalls as rustc_driver::CompilerCalls<'a>>::build_controller::{{closure}}
  23: _ZN12rustc_driver6driver13compile_input28_$u7b$$u7b$closure$u7d$$u7d$17h3bf6e8a918a767e2E.llvm.1EE5471B
  24: <std::thread::local::LocalKey<T>>::with
  25: <std::thread::local::LocalKey<T>>::with
  26: rustc::ty::context::TyCtxt::create_and_enter
  27: rustc_driver::driver::compile_input
  28: rustc_driver::run_compiler
nrc added a commit to nrc/rust that referenced this issue Nov 7, 2017
This just handles a missing entry, doesn't try to recover, because I couldn't actually find a test case.

cc rust-lang/rls#558
@sfackler
Copy link
Member Author

sfackler commented Nov 9, 2017

I see this coming up a lot when e.g. adding a generic parameter to a type and fixing up all of the compilation errors. Seems like it could be due to the type signatures of a method changing from the saved analysis of the last working version of the crate to what it looks like with the changes?

@nrc nrc added the bug label Nov 9, 2017
@nrc
Copy link
Member

nrc commented Jun 21, 2018

Have you seen this one recently?

@Xanewok
Copy link
Member

Xanewok commented Mar 3, 2019

I'll close this as stale; please reopen if that's still an issue!

@Xanewok Xanewok closed this as completed Mar 3, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

3 participants