rust/tests/ui/error-codes/E0186.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

14 lines
175 B
Rust
Raw Normal View History

2016-06-01 09:30:13 -05:00
trait Foo {
2016-08-04 12:56:12 -05:00
fn foo(&self); //~ `&self` used in trait
2016-06-01 09:30:13 -05:00
}
struct Bar;
impl Foo for Bar {
fn foo() {} //~ ERROR E0186
2016-08-04 12:56:12 -05:00
//~^ expected `&self` in impl
2016-06-01 09:30:13 -05:00
}
fn main() {
}