Closed
Description
When I try to compile the following code with rustc --crate-type lib test_error.rs
trait MyTrait<'a> {
fn yo(&'a self);
}
struct MyStruct<'a, 'b> {
inner: &'a MyTrait<'b>,
}
impl<'a,'b> MyStruct<'a, 'b> {
fn foo_inner(&mut self) {
self.inner.yo()
}
}
.. then I get the following ICE:
test_error.rs:12:9: 12:19 error: internal compiler error: cannot relate bound region: ReEarlyBound(10, 0, a) <= ReInfer(0)
This message reflects a bug in the Rust compiler.
We would appreciate a bug report: http://static.rust-lang.org/doc/master/complement-bugreport.html
test_error.rs:12 self.inner.yo()
Possibly related to #5121
Metadata
Metadata
Assignees
Labels
No labels