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 panic - Referenced variable location is not an alloca! #20312

Closed
jonasp opened this issue Dec 29, 2014 · 2 comments · Fixed by #20407
Closed

compiler panic - Referenced variable location is not an alloca! #20312

jonasp opened this issue Dec 29, 2014 · 2 comments · Fixed by #20407
Labels
A-debuginfo Area: Debugging information in compiled programs (DWARF, PDB, etc.) I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️

Comments

@jonasp
Copy link

jonasp commented Dec 29, 2014

This little program causes a compiler panic:

fn main() {
  return;
  let a = "";
}

The error message is the following:

error: internal compiler error: debuginfo::create_local_var_metadata() - Referenced variable location is not an alloca!

thread 'rustc' panicked at 'Box<Any>', /Users/rustbuild/src/rust-buildbot/slave/nightly-mac/build/src/libsyntax/diagnostic.rs:123

stack backtrace:
   1:        0x1110d3460 - sys::backtrace::write::hd64c72d07de40cf8tbt
   2:        0x1110f3817 - failure::on_fail::h646e1201dbb0ef3bNhz
   3:        0x11106570a - rt::unwind::begin_unwind_inner::hec294e47b94ba78aiZy
   4:        0x10ef6fc57 - rt::unwind::begin_unwind::h558350071601703502
   5:        0x10ef6fbe4 - diagnostic::SpanHandler::span_bug::he3912bc404042fc4LQF
   6:        0x10e40930d - session::Session::span_bug::h5801ed3acd26a48eY4l
   7:        0x10dbbfa8e - middle::pat_util::pat_bindings::closure.48598
   8:        0x10ef3a3f1 - ast_util::walk_pat::hbe1ce29526693031GsC
   9:        0x10daafca0 - trans::controlflow::trans_block::h956d3c669c21aa441Vd
  10:        0x10db6c487 - trans::base::trans_closure::h98002b90cdeb7941jSt
  11:        0x10daa4326 - trans::base::trans_fn::h68450a8b056829a432t
  12:        0x10da9faec - trans::base::trans_item::h8a58a6cf2c6184c8Vnu
  13:        0x10db72f18 - trans::base::trans_crate::h35254e15f256e4f14iv
  14:        0x10d870560 - driver::phase_4_translate_to_llvm::h2943144b3698b013mDa
  15:        0x10d8478b3 - driver::compile_input::hd01e9035001db87cwba
  16:        0x10d9e5d54 - thunk::F.Invoke<A,$u{20}R$GT$::invoke::h356901253070274503
  17:        0x10d9e2670 - rt::unwind::try::try_fn::h13338831715023405046
  18:        0x11115b029 - rust_try_inner
  19:        0x11115b016 - rust_try
  20:        0x10d9e2d6b - thunk::F.Invoke<A,$u{20}R$GT$::invoke::h15972762549593096795
  21:        0x1110e2de4 - sys::thread::thread_start::h719786e0e5fa53d4b1v
  22:     0x7fff8e9742fc - _pthread_body
  23:     0x7fff8e974279 - _pthread_body
@jonasp jonasp changed the title compiler panic compiler panic - Referenced variable location is not an alloca! Dec 29, 2014
@huonw huonw added I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️ A-debuginfo Area: Debugging information in compiled programs (DWARF, PDB, etc.) labels Dec 29, 2014
@huonw
Copy link
Member

huonw commented Dec 29, 2014

cc @michaelwoerister

@michaelwoerister
Copy link
Member

Good catch, @jonasp! I'll fix this shortly.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-debuginfo Area: Debugging information in compiled programs (DWARF, PDB, etc.) I-ICE Issue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants