1
- error[E0478]: lifetime bound not satisfied
2
- --> $DIR/closure_wf_outlives.rs:14:27
3
- |
4
- LL | type Opaque<'a, 'b> = impl Sized + 'a + 'b;
5
- | ^^^^^^^^^^^^^^^^^^^^
6
- |
7
- note: lifetime parameter instantiated with the lifetime `'a` as defined here
8
- --> $DIR/closure_wf_outlives.rs:14:17
9
- |
10
- LL | type Opaque<'a, 'b> = impl Sized + 'a + 'b;
11
- | ^^
12
- note: but lifetime parameter must outlive the lifetime `'b` as defined here
13
- --> $DIR/closure_wf_outlives.rs:14:21
14
- |
15
- LL | type Opaque<'a, 'b> = impl Sized + 'a + 'b;
16
- | ^^
17
-
18
- error[E0495]: cannot infer an appropriate lifetime due to conflicting requirements
19
- --> $DIR/closure_wf_outlives.rs:27:27
20
- |
21
- LL | type Opaque<'a, 'b> = impl Sized + 'a + 'b;
22
- | ^^^^^^^^^^^^^^^^^^^^
23
- |
24
- note: first, the lifetime cannot outlive the lifetime `'a` as defined here...
25
- --> $DIR/closure_wf_outlives.rs:27:17
26
- |
27
- LL | type Opaque<'a, 'b> = impl Sized + 'a + 'b;
28
- | ^^
29
- note: ...so that the declared lifetime parameter bounds are satisfied
30
- --> $DIR/closure_wf_outlives.rs:27:27
31
- |
32
- LL | type Opaque<'a, 'b> = impl Sized + 'a + 'b;
33
- | ^^^^^^^^^^^^^^^^^^^^
34
- note: but, the lifetime must be valid for the lifetime `'b` as defined here...
35
- --> $DIR/closure_wf_outlives.rs:27:21
36
- |
37
- LL | type Opaque<'a, 'b> = impl Sized + 'a + 'b;
38
- | ^^
39
- note: ...so that the declared lifetime parameter bounds are satisfied
40
- --> $DIR/closure_wf_outlives.rs:27:27
41
- |
42
- LL | type Opaque<'a, 'b> = impl Sized + 'a + 'b;
43
- | ^^^^^^^^^^^^^^^^^^^^
44
-
45
1
error[E0310]: the parameter type `T` may not live long enough
46
- --> $DIR/closure_wf_outlives.rs:54 :22
2
+ --> $DIR/closure_wf_outlives.rs:47 :22
47
3
|
48
4
LL | type Opaque<T> = impl Sized;
49
5
| ^^^^^^^^^^ ...so that the type `T` will meet its required lifetime bounds...
50
6
|
51
7
note: ...that is required by this bound
52
- --> $DIR/closure_wf_outlives.rs:59 :12
8
+ --> $DIR/closure_wf_outlives.rs:52 :12
53
9
|
54
10
LL | T: 'static,
55
11
| ^^^^^^^
@@ -58,7 +14,6 @@ help: consider adding an explicit lifetime bound...
58
14
LL | type Opaque<T: 'static> = impl Sized;
59
15
| +++++++++
60
16
61
- error: aborting due to 3 previous errors
17
+ error: aborting due to previous error
62
18
63
- Some errors have detailed explanations: E0310, E0478, E0495.
64
- For more information about an error, try `rustc --explain E0310`.
19
+ For more information about this error, try `rustc --explain E0310`.
0 commit comments