blob: 8ff924ccc2a89860482edb2e317f367eec9e2baf [file] [log] [blame]
struct Foo {
}
impl Foo {
fn method(&mut self, foo: &mut Foo) {
}
}
fn main() {
let mut foo = Foo { };
foo.method(&mut foo);
//~^ ERROR cannot borrow `foo` as mutable more than once at a time
//~^^ ERROR cannot borrow `foo` as mutable more than once at a time
}