mirror of
https://github.com/rust-lang/rust.git
synced 2024-12-24 14:34:23 +00:00
15 lines
288 B
Rust
15 lines
288 B
Rust
#![feature(auto_traits)]
|
|
|
|
auto trait Foo {
|
|
fn g(&self); //~ ERROR auto traits cannot have associated items
|
|
}
|
|
|
|
trait Bar {
|
|
fn f(&self) {
|
|
// issue #105788
|
|
self.g(); //~ ERROR no method named `g` found for reference `&Self` in the current scope
|
|
}
|
|
}
|
|
|
|
fn main() {}
|