error[E0597]: `f1` does not live long enough --> $DIR/dst-bad-coerce3.rs:14:32 | LL | fn baz<'a>() { | -- lifetime `'a` defined here LL | // With a vec of ints. LL | let f1 = Fat { ptr: [1, 2, 3] }; | -- binding `f1` declared here LL | let f2: &Fat<[isize; 3]> = &f1; | ^^^ borrowed value does not live long enough LL | let f3: &'a Fat<[isize]> = f2; | ---------------- type annotation requires that `f1` is borrowed for `'a` ... LL | } | - `f1` dropped here while still borrowed error[E0597]: `f1` does not live long enough --> $DIR/dst-bad-coerce3.rs:19:25 | LL | fn baz<'a>() { | -- lifetime `'a` defined here ... LL | let f1 = Fat { ptr: Foo }; | -- binding `f1` declared here LL | let f2: &Fat = &f1; | ^^^ borrowed value does not live long enough LL | let f3: &'a Fat = f2; | ---------------- type annotation requires that `f1` is borrowed for `'a` LL | } | - `f1` dropped here while still borrowed error: aborting due to 2 previous errors For more information about this error, try `rustc --explain E0597`.