Skip to content

OSX only ICE using plugin_register #16856

Closed
@jasonroelofs

Description

@jasonroelofs

I ran into this issue trying to build the https://github.com/bjz/gl-rs project. I was able to pair the code down to a minimal required set that triggers this ICE. As the minimal is multiple files I've prepared a repository such that it's easy to test this in three steps.

[repo deleted]

What's particularly strange is that this only throws on OSX. My linux machine has no problem, and multiple people in #rust_gamedev are on Windows and use gl-rs regularly with no issue.

Here's the stack:

error: internal compiler error: unexpected failure
note: the compiler hit an unexpected failure path. this is a bug.
note: we would appreciate a bug report: http://doc.rust-lang.org/complement-bugreport.html
note: run with `RUST_BACKTRACE=1` for a backtrace
task 'rustc' failed at 'index out of bounds: the len is 56 but the index is 60', /private/tmp/rust-g7z3JE/src/libsyntax/lib.rs:1

stack backtrace:
   1:        0x10fbb5335 - rt::backtrace::imp::write::h6b086cc6e4a0277ai9q
   2:        0x10fbb86b3 - failure::on_fail::h0f81c721549aaa0ebqr
   3:        0x10fe78923 - unwind::begin_unwind_inner::h9ccd054f5e442a0e4fe
   4:        0x10fe78575 - unwind::begin_unwind_fmt::h167e44acc4103cb6ude
   5:        0x10fe783a2 - rust_begin_unwind
   6:        0x10fec427c - failure::begin_unwind::h551715f98d5a21280zk
   7:        0x10fec9556 - failure::fail_bounds_check::hb244088457424e6bcyk
   8:        0x1163efaa2 - util::interner::StrInterner::get::h48e2b49ca7acec9cZpa
   9:        0x116404698 - ast::Name::as_str::h6f78683b28420a41mPb
  10:        0x1164a92e0 - parse::parser::Parser<'a>::lit_from_token::h3595dc6e621d333dx7L
  11:        0x1164adb1c - parse::parser::Parser<'a>::parse_lit::h63be68bced529bcfB9L
  12:        0x1164b14a3 - parse::parser::Parser<'a>::parse_bottom_expr::hb4689d131d8b82157qM
  13:        0x1164b6897 - parse::parser::Parser<'a>::parse_dot_or_call_expr::h262b4643f2c2da19LJM
  14:        0x1164b9a48 - parse::parser::Parser<'a>::parse_prefix_expr::h9cf53632dffcd8bfF1M
  15:        0x1164b9e77 - parse::parser::Parser<'a>::parse_binops::h4e521c814541f283R6M
  16:        0x1164ba79d - parse::parser::Parser<'a>::parse_assign_expr::h8d9d914e489932f8kaN
  17:        0x116517b0b - ext::base::get_exprs_from_tts::h45f2b069f289dc64yT3
  18:        0x1103459fa - macro_handler::h7551bfd811b168bdYba
  19:        0x10f36ddda - ext::base::BasicMacroExpander.TTMacroExpander::expand::h2baf24ba9a7d5ce5ao3
  20:        0x10f3f6829 - ext::expand::expand_item_mac::ha663cdd153576148xda
  21:        0x10f3f3ef8 - ext::expand::expand_item::hba41efe93fdcafe8e59
  22:        0x10f3fb773 - ext::expand::MacroExpander<'a, 'b>.Folder::fold_item::h13f1007332cccf23wRa
  23:        0x10f3fb70c - fold::noop_fold_mod::closure.51796
  24:        0x10f39eadb - iter::Iterator::collect::h11959690785247035432
  25:        0x10f3fae1c - fold::Folder::fold_mod::h15293868271147069927
  26:        0x10f42af87 - ext::expand::expand_crate::h1c4f9fc1f596a1bcpUa
  27:        0x10d31400c - driver::driver::phase_2_configure_and_expand::closure.134908
  28:        0x10d13d8c1 - driver::driver::phase_2_configure_and_expand::h75de81d8bf8c4cb1piy
  29:        0x10d2daec2 - driver::driver::compile_input::h10872f44b013a593Qby
  30:        0x10d366567 - driver::run_compiler::h8e876bac459a8495JIB
  31:        0x10d364ca6 - driver::main_args::closure.138220
  32:        0x10d37655b - task::TaskBuilder<S>::try_future::closure.139333
  33:        0x10d376463 - task::TaskBuilder<S>::spawn_internal::closure.139310
  34:        0x10ca5e6fc - task::spawn_opts::closure.8457
  35:        0x10feda80c - rust_try_inner
  36:        0x10feda7f6 - rust_try
  37:        0x10fe75d77 - unwind::try::h9ff6d49cd7168a36k4d
  38:        0x10fe75b3b - task::Task::run::h364d323a1b0e9c2bbbd
  39:        0x10ca5e542 - task::spawn_opts::closure.8402
  40:        0x10fe778b6 - thread::thread_start::hf671dbfd5877000bXzd
  41:     0x7fff96c38899 - _pthread_body
  42:     0x7fff96c3872a - _pthread_struct_init

Could not compile `plugin-ice`.

Metadata

Metadata

Assignees

No one assigned

    Labels

    I-ICEIssue: The compiler panicked, giving an Internal Compilation Error (ICE) ❄️

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions