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

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

11 lines
171 B
Rust
Raw Normal View History

2016-08-03 23:51:52 +00:00
trait MyTrait { type X; }
struct MyStruct;
impl MyTrait for MyStruct {
type X = ();
}
2016-08-03 23:51:52 +00:00
fn main() {
2016-08-06 03:41:25 +00:00
let foo: MyTrait::X;
//~^ ERROR ambiguous associated type
2016-08-03 23:51:52 +00:00
}