Closed
Description
xyz.rs
:
trait X {
fn call(&self);
}
struct Y;
struct Z<T: X> {
x: T
}
impl Y: X {
fn call(&self) {
}
}
impl<T: X> Z<T>: Drop {
fn finalize(&self) {
self.x.call(); // Adding this statement causes an ICE.
}
}
fn main() {
let y = Y;
let _z = Z{x: y};
}
$ RUST_LOG=rustc=1,::rt::backtrace rustc xyz.rs
rust: task failed at 'option::get none', /Users/tychosci/pkg/rust/src/librustc/rustc.rc:1
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=1,::rt::backtrace to get further details and report the results to github.com/mozilla/rust/issues
rust: task failed at 'explicit failure', /Users/tychosci/pkg/rust/src/librustc/rustc.rc:425
rust: domain main @0x7feecb000010 root task failed
rust: task failed at 'killed', /Users/tychosci/pkg/rust/src/libcore/task/mod.rs:570