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

Compiler panics on build #37999

Closed
vitiral opened this issue Nov 25, 2016 · 2 comments
Closed

Compiler panics on build #37999

vitiral opened this issue Nov 25, 2016 · 2 comments

Comments

@vitiral
Copy link
Contributor

vitiral commented Nov 25, 2016

The compiler is panicking on commit 8361e35 of my project when I call cargo build:

# cargo build
   Compiling rst_app v0.2.1 (file:///home/garrett/projects/rst)
error: internal compiler error: unexpected panic                                                                                                                                                            [0/807]

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: run with `RUST_BACKTRACE=1` for a backtrace

thread 'rustc' panicked at 'index out of bounds: the len is 360124 but the index is 360124', ../src/libserialize/leb128.rs:46
stack backtrace:
   1:     0x7f949587585f - std::sys::backtrace::tracing::imp::write::h6f1d53a70916b90d
   2:     0x7f9495884dbd - std::panicking::default_hook::{{closure}}::h137e876f7d3b5850
   3:     0x7f949588222e - std::panicking::default_hook::h0ac3811ec7cee78c
   4:     0x7f9495882918 - std::panicking::rust_panic_with_hook::hc303199e04562edf
   5:     0x7f94958827b2 - std::panicking::begin_panic::h6ed03353807cf54d
   6:     0x7f94958826f0 - std::panicking::begin_panic_fmt::hc321cece241bb2f5
   7:     0x7f9495882671 - rust_begin_unwind
   8:     0x7f94958cffff - core::panicking::panic_fmt::h27224b181f9f037f
   9:     0x7f94958cffa3 - core::panicking::panic_bounds_check::h19e9bbc59320a57e
  10:     0x7f948ec302ef - <serialize::opaque::Decoder<'a> as serialize::serialize::Decoder>::read_usize::hdb6b9929c2878103
  11:     0x7f9493509798 - rustc_metadata::decoder::<impl rustc_metadata::cstore::MetadataBlob>::get_root::ha0bece0640a71bb4
  12:     0x7f94935323bf - rustc_metadata::loader::Context::extract_one::h893f537a80fcaa7b
  13:     0x7f949352f729 - rustc_metadata::loader::Context::find_library_crate::h0ae9ebab39601e07
  14:     0x7f949351e0b9 - rustc_metadata::creader::CrateReader::load::hbbb9048f37b5929d
  15:     0x7f949351d4d8 - rustc_metadata::creader::CrateReader::resolve_crate::h0ea8ce3f005d5018
  16:     0x7f949353b59a - rustc_metadata::creader::CrateReader::resolve_crate_deps::{{closure}}::hba6352ef73c55dfc
  17:     0x7f94934afc16 - <std::collections::hash::map::HashMap<K, V, S> as core::iter::traits::FromIterator<(K, V)>>::from_iter::hfdd794029d934f9e
  18:     0x7f949351b84f - rustc_metadata::creader::CrateReader::register_crate::h5c79c40329468538
  19:     0x7f94935228bb - rustc_metadata::creader::CrateReader::read_macros::hbcdddd25556965a6
  20:     0x7f94935355db - rustc_metadata::macro_import::load_macros::hf8ed055f967f056a
  21:     0x7f9493527d0b - <rustc_metadata::creader::CrateLoader<'a> as rustc::middle::cstore::CrateLoader>::load_macros::h1c3dc5592ec08b80
  22:     0x7f9494e7c104 - <rustc_resolve::macros::ExpansionVisitor<'a, 'b> as syntax::visit::Visitor>::visit_item::he806776e3c2c5c85
  23:     0x7f9494e732ef - syntax::visit::walk_item::h9ee859a018283218
  24:     0x7f9494e7ceaa - <rustc_resolve::macros::ExpansionVisitor<'a, 'b> as syntax::visit::Visitor>::visit_item::he806776e3c2c5c85
  25:     0x7f9494e79b9a - rustc_resolve::macros::<impl syntax::ext::base::Resolver for rustc_resolve::Resolver<'a>>::visit_expansion::h095f31c8c14629f1
  26:     0x7f948f4790e6 - syntax::ext::expand::MacroExpander::collect_invocations::h3001d1fc85715c10
  27:     0x7f948f475432 - syntax::ext::expand::MacroExpander::expand::hba1d6fcc6652f3dc
  28:     0x7f948f474c92 - syntax::ext::expand::MacroExpander::expand_crate::hee7239fe3665f838
  29:     0x7f948f480eed - syntax::ext::expand::expand_crate::h9213ee787f1c5e5d
  30:     0x7f9495c40b5d - rustc_driver::driver::phase_2_configure_and_expand::{{closure}}::hb36e77d125a4fd93
  31:     0x7f9495bf548f - rustc_driver::driver::phase_2_configure_and_expand::h2f62e5b496da5c2b
  32:     0x7f9495beeefb - rustc_driver::driver::compile_input::hef221f9f618e92f5
  33:     0x7f9495c1b206 - rustc_driver::run_compiler::h7dddd4089f8330b4
  34:     0x7f9495b572c3 - std::panicking::try::do_call::h1e3ece12e3f812df
  35:     0x7f949588ccb6 - __rust_maybe_catch_panic
  36:     0x7f9495b754f9 - <F as alloc::boxed::FnBox<A>>::call_box::h05b222e46803eb30
  37:     0x7f9495880c80 - std::sys::thread::Thread::new::thread_start::h759e10bc4abc7e72
  38:     0x7f948e7f5453 - start_thread
  39:     0x7f94955517de - __GI___clone
  40:                0x0 - <unknown>

error: Could not compile `rst_app`.

To learn more, run the command again with --verbose.

When I run with nightly-x86_64-unknown-linux-gnu unchanged - rustc 1.15.0-nightly (7b3eeea22 2016-11-21) it seems to work.

@est31
Copy link
Member

est31 commented Nov 25, 2016

This looks like a dupe of #37803 .

Is the bug gone when you rename your target directory? (don't delete it but keep it around for the case its no dupe and people want to investigate more)

@vitiral
Copy link
Contributor Author

vitiral commented Nov 25, 2016

yup, that resolved the issue. Thanks!

@vitiral vitiral closed this as completed Nov 25, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants