blob: b365e07feb28a957e7e3ad9bc9bf420199591505 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
// check-fail
#![feature(specialization)]
//~^ WARN incomplete
#![feature(generic_associated_types)]
trait Family {
type Member<'a>: for<'b> PartialEq<Self::Member<'b>>;
}
struct I32Family;
impl Family for I32Family {
default type Member<'a> = i32;
}
struct Foo;
struct FooFamily;
impl Family for FooFamily {
default type Member<'a> = Foo;
//~^ ERROR can't compare
}
fn main() {}
|