]> git.proxmox.com Git - rustc.git/blame - src/test/ui/generic-associated-types/projection-type-lifetime-mismatch.stderr
Merge tag 'debian/1.52.1+dfsg1-1_exp2' into proxmox/buster
[rustc.git] / src / test / ui / generic-associated-types / projection-type-lifetime-mismatch.stderr
CommitLineData
6a06907d
XL
1error[E0621]: explicit lifetime required in the type of `x`
2 --> $DIR/projection-type-lifetime-mismatch.rs:18:5
3 |
4LL | fn f(x: &impl for<'a> X<Y<'a> = &'a ()>) -> &'static () {
5 | ------------------------------- help: add explicit lifetime `'static` to the type of `x`: `&'static impl for<'a> X<Y<'a> = &'a ()>`
6LL | x.m()
7 | ^^^^^ lifetime `'static` required
8
9error[E0621]: explicit lifetime required in the type of `x`
10 --> $DIR/projection-type-lifetime-mismatch.rs:23:5
11 |
12LL | fn g<T: for<'a> X<Y<'a> = &'a ()>>(x: &T) -> &'static () {
13 | -- help: add explicit lifetime `'static` to the type of `x`: `&'static T`
14LL | x.m()
15 | ^^^^^ lifetime `'static` required
16
17error[E0621]: explicit lifetime required in the type of `x`
18 --> $DIR/projection-type-lifetime-mismatch.rs:28:5
19 |
20LL | fn h(x: &()) -> &'static () {
21 | --- help: add explicit lifetime `'static` to the type of `x`: `&'static ()`
22LL | x.m()
23 | ^^^^^ lifetime `'static` required
24
25error: aborting due to 3 previous errors
26
27For more information about this error, try `rustc --explain E0621`.