blob: ff265e576b90f2fb0e1a3f9954f38679f2bf0b93 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
trait Foo<T> {
fn foo<F2>(self) -> impl Foo<T>;
}
struct Bar;
impl Foo<char> for Bar {
fn foo<F2: Foo<u8>>(self) -> impl Foo<u8> {
//~^ ERROR: the trait bound `impl Foo<u8>: Foo<char>` is not satisfied [E0277]
//~| ERROR: the trait bound `Bar: Foo<u8>` is not satisfied [E0277]
//~| ERROR: impl has stricter requirements than trait
self
}
}
fn main() {}
|