2018-12-11 15:49:40 -06:00
|
|
|
error: lifetime may not live long enough
|
2018-12-25 08:56:47 -07:00
|
|
|
--> $DIR/regions-static-bound.rs:9:5
|
2018-08-08 14:28:26 +02:00
|
|
|
|
|
|
|
|
LL | fn static_id_wrong_way<'a>(t: &'a ()) -> &'static () where 'static: 'a {
|
|
|
|
| -- lifetime `'a` defined here
|
2019-03-17 10:52:07 +01:00
|
|
|
LL | t
|
2018-08-14 21:26:33 +01:00
|
|
|
| ^ returning this value requires that `'a` must outlive `'static`
|
2018-11-28 15:05:36 -06:00
|
|
|
|
2018-08-08 14:28:26 +02:00
|
|
|
error[E0621]: explicit lifetime required in the type of `u`
|
2018-12-25 08:56:47 -07:00
|
|
|
--> $DIR/regions-static-bound.rs:14:5
|
2018-08-08 14:28:26 +02:00
|
|
|
|
|
2019-03-17 10:52:07 +01:00
|
|
|
LL | static_id(&u);
|
2018-08-08 14:28:26 +02:00
|
|
|
| ^^^^^^^^^^^^^ lifetime `'static` required
|
|
|
|
|
|
|
|
error[E0621]: explicit lifetime required in the type of `v`
|
2018-12-25 08:56:47 -07:00
|
|
|
--> $DIR/regions-static-bound.rs:16:5
|
2018-08-08 14:28:26 +02:00
|
|
|
|
|
2019-03-17 10:52:07 +01:00
|
|
|
LL | static_id_indirect(&v);
|
2018-08-08 14:28:26 +02:00
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^ lifetime `'static` required
|
|
|
|
|
2018-10-22 11:20:17 -04:00
|
|
|
error: aborting due to 3 previous errors
|
2018-08-08 14:28:26 +02:00
|
|
|
|
|
|
|
For more information about this error, try `rustc --explain E0621`.
|