error[E0597]: `x` does not live long enough --> $DIR/region-borrow-params-issue-29793-big.rs:81:43 | LL | WrapB::new().set(|t: bool| if t { x } else { y }) // (separate errors for `x` vs `y`) | --------- ^ borrowed value does not live long enough | | | capture occurs here ... LL | }); | - borrowed value dropped before borrower | = note: values in a scope are dropped in the opposite order they are created error[E0597]: `y` does not live long enough --> $DIR/region-borrow-params-issue-29793-big.rs:81:54 | LL | WrapB::new().set(|t: bool| if t { x } else { y }) // (separate errors for `x` vs `y`) | --------- ^ borrowed value does not live long enough | | | capture occurs here ... LL | }); | - borrowed value dropped before borrower | = note: values in a scope are dropped in the opposite order they are created error: aborting due to 2 previous errors For more information about this error, try `rustc --explain E0597`.