rust/src/test/ui/issues/issue-19538.rs
2018-12-25 21:08:33 -07:00

21 lines
285 B
Rust

trait Foo {
fn foo<T>(&self, val: T);
}
trait Bar: Foo { }
pub struct Thing;
impl Foo for Thing {
fn foo<T>(&self, val: T) { }
}
impl Bar for Thing { }
fn main() {
let mut thing = Thing;
let test: &mut Bar = &mut thing;
//~^ ERROR E0038
//~| ERROR E0038
}