2018-10-08 18:03:24 -05:00
|
|
|
error[E0597]: `y` does not live long enough
|
2019-04-07 10:07:36 -05:00
|
|
|
--> $DIR/pattern_substs_on_tuple_struct.rs:5:19
|
2018-10-08 18:03:24 -05:00
|
|
|
|
|
|
|
|
LL | let foo = Foo(&y);
|
|
|
|
| ^^ borrowed value does not live long enough
|
2019-03-09 06:03:44 -06:00
|
|
|
LL |
|
2018-10-14 09:12:02 -05:00
|
|
|
LL | let Foo::<'static>(_z) = foo;
|
|
|
|
| ------------------ type annotation requires that `y` is borrowed for `'static`
|
2018-10-08 18:03:24 -05:00
|
|
|
LL | }
|
|
|
|
| - `y` dropped here while still borrowed
|
|
|
|
|
|
|
|
error[E0597]: `y` does not live long enough
|
2019-04-07 10:07:36 -05:00
|
|
|
--> $DIR/pattern_substs_on_tuple_struct.rs:12:19
|
2018-10-08 18:03:24 -05:00
|
|
|
|
|
|
|
|
LL | let foo = Foo(&y);
|
|
|
|
| ^^ borrowed value does not live long enough
|
|
|
|
...
|
2018-10-14 09:12:02 -05:00
|
|
|
LL | Foo::<'static>(_z) => {
|
|
|
|
| ------------------ type annotation requires that `y` is borrowed for `'static`
|
|
|
|
...
|
2018-10-08 18:03:24 -05:00
|
|
|
LL | }
|
|
|
|
| - `y` dropped here while still borrowed
|
|
|
|
|
|
|
|
error: aborting due to 2 previous errors
|
|
|
|
|
|
|
|
For more information about this error, try `rustc --explain E0597`.
|