]> git.proxmox.com Git - rustc.git/blame - src/test/ui/generic-associated-types/unsatified-item-lifetime-bound.stderr
New upstream version 1.65.0+dfsg1
[rustc.git] / src / test / ui / generic-associated-types / unsatified-item-lifetime-bound.stderr
CommitLineData
6a06907d 1warning: unnecessary lifetime parameter `'a`
f2b60f7d 2 --> $DIR/unsatified-item-lifetime-bound.rs:2:12
6a06907d
XL
3 |
4LL | type Y<'a: 'static>;
04454e1e 5 | ^^
6a06907d
XL
6 |
7 = help: you can use the `'static` lifetime directly, in place of `'a`
8
9error[E0478]: lifetime bound not satisfied
f2b60f7d 10 --> $DIR/unsatified-item-lifetime-bound.rs:11:8
6a06907d
XL
11 |
12LL | f: <T as X>::Y<'a>,
13 | ^^^^^^^^^^^^^^^
14 |
c295e0f8 15note: lifetime parameter instantiated with the lifetime `'a` as defined here
f2b60f7d 16 --> $DIR/unsatified-item-lifetime-bound.rs:10:10
6a06907d
XL
17 |
18LL | struct B<'a, T: for<'r> X<Y<'r> = &'r ()>> {
19 | ^^
20 = note: but lifetime parameter must outlive the static lifetime
21
22error[E0478]: lifetime bound not satisfied
f2b60f7d 23 --> $DIR/unsatified-item-lifetime-bound.rs:16:8
6a06907d
XL
24 |
25LL | f: <T as X>::Y<'a>,
26 | ^^^^^^^^^^^^^^^
27 |
c295e0f8 28note: lifetime parameter instantiated with the lifetime `'a` as defined here
f2b60f7d 29 --> $DIR/unsatified-item-lifetime-bound.rs:15:10
6a06907d
XL
30 |
31LL | struct C<'a, T: X> {
32 | ^^
33 = note: but lifetime parameter must outlive the static lifetime
34
35error[E0478]: lifetime bound not satisfied
f2b60f7d 36 --> $DIR/unsatified-item-lifetime-bound.rs:21:8
6a06907d
XL
37 |
38LL | f: <() as X>::Y<'a>,
39 | ^^^^^^^^^^^^^^^^
40 |
c295e0f8 41note: lifetime parameter instantiated with the lifetime `'a` as defined here
f2b60f7d 42 --> $DIR/unsatified-item-lifetime-bound.rs:20:10
6a06907d
XL
43 |
44LL | struct D<'a> {
45 | ^^
46 = note: but lifetime parameter must outlive the static lifetime
47
48error: aborting due to 3 previous errors; 1 warning emitted
49
50For more information about this error, try `rustc --explain E0478`.