fork/rust

git clone https://git.julia.blue/fork/rust

borsAuto merge of #72883 - Mark-Simulacrum:stable-next, r=Mark-Simulacrum49cae55760d

1.44.0
2.0 KiB50 linesraw
1error: implementation of `Foo` is not general enough
2  --> $DIR/auto-trait-regions.rs:31:5
3   |
4LL | auto trait Foo {}
5   | ----------------- trait `Foo` defined here
6...
7LL |     assert_foo(gen);
8   |     ^^^^^^^^^^ implementation of `Foo` is not general enough
9   |
10   = note: `Foo` would have to be implemented for the type `&'0 OnlyFooIfStaticRef`, for any lifetime `'0`...
11   = note: ...but `Foo` is actually implemented for the type `&'1 OnlyFooIfStaticRef`, for some specific lifetime `'1`
12
13error: implementation of `Foo` is not general enough
14  --> $DIR/auto-trait-regions.rs:31:5
15   |
16LL | auto trait Foo {}
17   | ----------------- trait `Foo` defined here
18...
19LL |     assert_foo(gen);
20   |     ^^^^^^^^^^ implementation of `Foo` is not general enough
21   |
22   = note: `Foo` would have to be implemented for the type `&'0 OnlyFooIfStaticRef`, for any lifetime `'0`...
23   = note: ...but `Foo` is actually implemented for the type `&'1 OnlyFooIfStaticRef`, for some specific lifetime `'1`
24
25error: implementation of `Foo` is not general enough
26  --> $DIR/auto-trait-regions.rs:50:5
27   |
28LL | auto trait Foo {}
29   | ----------------- trait `Foo` defined here
30...
31LL |     assert_foo(gen);
32   |     ^^^^^^^^^^ implementation of `Foo` is not general enough
33   |
34   = note: `Foo` would have to be implemented for the type `A<'0, '1>`, for any two lifetimes `'0` and `'1`...
35   = note: ...but `Foo` is actually implemented for the type `A<'_, '2>`, for some specific lifetime `'2`
36
37error: implementation of `Foo` is not general enough
38  --> $DIR/auto-trait-regions.rs:50:5
39   |
40LL | auto trait Foo {}
41   | ----------------- trait `Foo` defined here
42...
43LL |     assert_foo(gen);
44   |     ^^^^^^^^^^ implementation of `Foo` is not general enough
45   |
46   = note: `Foo` would have to be implemented for the type `A<'0, '1>`, for any two lifetimes `'0` and `'1`...
47   = note: ...but `Foo` is actually implemented for the type `A<'_, '2>`, for some specific lifetime `'2`
48
49error: aborting due to 4 previous errors
50