]> git.lizzy.rs Git - rust.git/blob - src/test/ui/rfcs/rfc-2528-type-changing-struct-update/lifetime-update.stderr
Rollup merge of #85766 - workingjubilee:file-options, r=yaahc
[rust.git] / src / test / ui / rfcs / rfc-2528-type-changing-struct-update / lifetime-update.stderr
1 error[E0597]: `s` does not live long enough
2   --> $DIR/lifetime-update.rs:20:17
3    |
4 LL |         lt_str: &s,
5    |                 ^^ borrowed value does not live long enough
6 ...
7 LL |     let m2: Machine<'static, State1> = Machine {
8    |             ------------------------ type annotation requires that `s` is borrowed for `'static`
9 ...
10 LL | }
11    | - `s` dropped here while still borrowed
12
13 error: aborting due to previous error
14
15 For more information about this error, try `rustc --explain E0597`.