summaryrefslogtreecommitdiffstats
path: root/tests/ui/nll/ty-outlives/wf-unreachable.stderr
blob: da3bc20832286aab2f63f8e0e2fc1e6b5e0febd6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
error: lifetime may not live long enough
  --> $DIR/wf-unreachable.rs:6:12
   |
LL | fn uninit<'a>() {
   |           -- lifetime `'a` defined here
LL |     return;
LL |     let x: &'static &'a ();
   |            ^^^^^^^^^^^^^^^ requires that `'a` must outlive `'static`

error: lifetime may not live long enough
  --> $DIR/wf-unreachable.rs:11:12
   |
LL | fn var_type<'a>() {
   |             -- lifetime `'a` defined here
LL |     return;
LL |     let x: &'static &'a () = &&();
   |            ^^^^^^^^^^^^^^^ requires that `'a` must outlive `'static`

error: lifetime may not live long enough
  --> $DIR/wf-unreachable.rs:15:12
   |
LL | fn uninit_infer<'a>() {
   |                 -- lifetime `'a` defined here
LL |     let x: &'static &'a _;
   |            ^^^^^^^^^^^^^^ requires that `'a` must outlive `'static`

error: lifetime may not live long enough
  --> $DIR/wf-unreachable.rs:21:12
   |
LL | fn infer<'a>() {
   |          -- lifetime `'a` defined here
LL |     return;
LL |     let x: &'static &'a _ = &&();
   |            ^^^^^^^^^^^^^^ requires that `'a` must outlive `'static`

error: lifetime may not live long enough
  --> $DIR/wf-unreachable.rs:26:12
   |
LL | fn uninit_no_var<'a>() {
   |                  -- lifetime `'a` defined here
LL |     return;
LL |     let _: &'static &'a ();
   |            ^^^^^^^^^^^^^^^ requires that `'a` must outlive `'static`

error: lifetime may not live long enough
  --> $DIR/wf-unreachable.rs:31:12
   |
LL | fn no_var<'a>() {
   |           -- lifetime `'a` defined here
LL |     return;
LL |     let _: &'static &'a () = &&();
   |            ^^^^^^^^^^^^^^^ requires that `'a` must outlive `'static`

error: lifetime may not live long enough
  --> $DIR/wf-unreachable.rs:36:12
   |
LL | fn infer_no_var<'a>() {
   |                 -- lifetime `'a` defined here
LL |     return;
LL |     let _: &'static &'a _ = &&();
   |            ^^^^^^^^^^^^^^ requires that `'a` must outlive `'static`

error: lifetime may not live long enough
  --> $DIR/wf-unreachable.rs:49:12
   |
LL | fn required_substs<'a>() {
   |                    -- lifetime `'a` defined here
LL |     return;
LL |     let _: C<'static, 'a, _> = C((), &(), &());
   |            ^^^^^^^^^^^^^^^^^ requires that `'a` must outlive `'static`

error: aborting due to 8 previous errors