blob: 46a5c9e7ca01ee9b0c81420ea069f4b718aa01b7 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
// Test that we have one and only one associated type per ref.
pub trait Foo {
type A;
}
pub trait Bar {
type A;
}
pub fn f1<T>(a: T, x: T::A) {} //~ERROR associated type `A` not found
pub fn f2<T: Foo + Bar>(a: T, x: T::A) {} //~ERROR ambiguous associated type `A`
pub fn main() {}
|