]> git.proxmox.com Git - rustc.git/blob - src/test/ui/generics/issue-65285-incorrect-explicit-lifetime-name-needed.stderr
New upstream version 1.53.0+dfsg1
[rustc.git] / src / test / ui / generics / issue-65285-incorrect-explicit-lifetime-name-needed.stderr
1 error[E0637]: `&` without an explicit lifetime name cannot be used here
2 --> $DIR/issue-65285-incorrect-explicit-lifetime-name-needed.rs:5:37
3 |
4 LL | fn should_error<T>() where T : Into<&u32> {}
5 | ^ explicit lifetime name needed here
6
7 error[E0106]: missing lifetime specifier
8 --> $DIR/issue-65285-incorrect-explicit-lifetime-name-needed.rs:13:17
9 |
10 LL | fn bar<'b, L: X<&'b Nested<i32>>>(){}
11 | ^ expected named lifetime parameter
12 |
13 help: consider using the `'b` lifetime
14 |
15 LL | fn bar<'b, L: X<'b, &'b Nested<i32>>>(){}
16 | ^^^
17
18 error[E0106]: missing lifetime specifier
19 --> $DIR/issue-65285-incorrect-explicit-lifetime-name-needed.rs:9:21
20 |
21 LL | fn foo<'b, L: X<&'b Nested<K>>>();
22 | ^ expected named lifetime parameter
23 |
24 note: these named lifetimes are available to use
25 --> $DIR/issue-65285-incorrect-explicit-lifetime-name-needed.rs:8:9
26 |
27 LL | trait X<'a, K: 'a> {
28 | ^^
29 LL | fn foo<'b, L: X<&'b Nested<K>>>();
30 | ^^
31 help: consider using one of the available lifetimes here
32 |
33 LL | fn foo<'b, L: X<'lifetime, &'b Nested<K>>>();
34 | ^^^^^^^^^^
35
36 error: aborting due to 3 previous errors
37
38 Some errors have detailed explanations: E0106, E0637.
39 For more information about an error, try `rustc --explain E0106`.