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

ICE with metadata, ifaces, and generic functions #2380

Closed
erickt opened this issue May 13, 2012 · 3 comments
Closed

ICE with metadata, ifaces, and generic functions #2380

erickt opened this issue May 13, 2012 · 3 comments
Labels
A-linkage Area: linking into static, shared libraries and binaries
Milestone

Comments

@erickt
Copy link
Contributor

erickt commented May 13, 2012

Good morning,

I ran into an ICE when trying to return a generic implementation across a crate. Here's a reduced example of the bug:

https://gist.github.com/2689394

a.rs:

#[link(name = "a", vers = "0.0")];
#[crate_type = "lib"];

iface i<T> { }

fn f<T>() -> i<T> {
    impl <T> of i<T> for () { }

    () as i::<T>
}

b.rs:

use a;

fn main() {
    a::f::<()>();
}

Errors with:

./run-rustc a.rs
warning: no debug symbols in executable (-arch x86_64)
./run-rustc b.rs
rust: upcall fail 'lookup_item: id not found: 13', /Users/etryzelaar/Projects/rust/rust/src/rustc/metadata/decoder.rs:94
error: internal compiler error: unexpected failure
note: the compiler hit an unexpected failure path. this is a bug
note: try running with RUST_LOG=rustc=0,::rt::backtrace to get further details and report the results to github.com/mozilla/rust/issues
rust: upcall fail 'explicit failure', /Users/etryzelaar/Projects/rust/rust/src/rustc/driver/rustc.rs:248
rust: domain main @0x103000010 root task failed
rust: upcall fail 'killed', /Users/etryzelaar/Projects/rust/rust/src/libcore/task.rs:454
make: *** [all] Error 101
@jdm
Copy link
Contributor

jdm commented May 13, 2012

This might be another example of #2318.

@erickt
Copy link
Contributor Author

erickt commented May 13, 2012

@jdm: It doesn't look like it. I just did a make clean && make and I'm still getting the same error.

@ghost ghost assigned catamorphism May 17, 2012
@catamorphism
Copy link
Contributor

Dup of #2383. Added the test as an additional test case.

bors added a commit to rust-lang-ci/rust that referenced this issue Sep 22, 2022
isatty tweaks

`@saethlin` I realized we need to gate this behind the isolation flag, sorry. :/  The point of isolated mode is that it is 100% deterministic, so we cannot call host functions that might give different answers on different runs.
celinval pushed a commit to celinval/rust-dev that referenced this issue Jun 4, 2024
Co-authored-by: Qinheping Hu <qinhh@amazon.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-linkage Area: linking into static, shared libraries and binaries
Projects
None yet
Development

No branches or pull requests

3 participants