Skip to content

Simplest possible rust-call function will ICE #22566

Closed
@nagisa

Description

@nagisa
extern "rust-call" fn a() {}
fn main(){}
error: internal compiler error: unimplemented foreign functions with RustCall ABI
note: the compiler unexpectedly panicked. 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
thread 'rustc' panicked at 'Box<Any>', /home/rustbuild/src/rust-buildbot/slave/nightly-dist-rustc-linux/build/src/libsyntax/diagnostic.rs:189

stack backtrace:
   1:     0x7fd4dcd2da60 - sys::backtrace::write::h17046f691c944fd6wlB
   2:     0x7fd4dcd56650 - failure::on_fail::hc6163ed550dbd15faOK
   3:     0x7fd4dcc9ce10 - rt::unwind::begin_unwind_inner::hf466231ca0fbfbbdvsK
   4:     0x7fd4da0099c0 - rt::unwind::begin_unwind::h15994696547183619422
   5:     0x7fd4da00a180 - diagnostic::Handler::bug::h1bc3ded4b9cf6157abF
   6:     0x7fd4da00a280 - diagnostic::Handler::unimpl::h7925c715a3764a3cQbF
   7:     0x7fd4dafdc570 - session::Session::unimpl::h9bfd0f79c5452bebDes
   8:     0x7fd4dbab9a90 - trans::foreign::llvm_calling_convention::hf7ec188cc1fffae5BWB
   9:     0x7fd4db988b30 - trans::base::get_item_val::hc88b3b1356c15164vkv
  10:     0x7fd4db986410 - trans::base::trans_item::ha4ea07b91896bde9tPu
  11:     0x7fd4dba750f0 - trans::base::trans_crate::hc435c9fdb6f30ff4NMv
  12:     0x7fd4dd378250 - driver::phase_4_translate_to_llvm::hb02bd998f41b29a0wPa
  13:     0x7fd4dd351170 - driver::compile_input::h91ff1ed16e22d05cEba
  14:     0x7fd4dd424ea0 - run_compiler::h9c581f85e29a6b265bc
  15:     0x7fd4dd423500 - thunk::F.Invoke<A, R>::invoke::h5155567596601403298
  16:     0x7fd4dd4223f0 - rt::unwind::try::try_fn::h5629523784837248188
  17:     0x7fd4dcdc2f20 - rust_try_inner
  18:     0x7fd4dcdc2f10 - rust_try
  19:     0x7fd4dd4226a0 - thunk::F.Invoke<A, R>::invoke::h7807062886684583533
  20:     0x7fd4dcd42190 - sys::thread::thread_start::h57c9c75c73c301cbfVF
  21:     0x7fd4d6ce42b0 - start_thread
  22:     0x7fd4dc923249 - __clone
  23:                0x0 - <unknown>

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-bugCategory: This is a bug.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