fork/rust
git clone https://git.julia.blue/fork/rust
f3e1a954d2e
1.41.1
1error[E0495]: cannot infer an appropriate lifetime for lifetime parameter 'r in function call due to conflicting requirements 2 --> $DIR/regions-infer-call-3.rs:8:24 3 | 4LL | let z = with(|y| { select(x, y) }); 5 | ^^^^^^^^^^^^ 6 | 7note: first, the lifetime cannot outlive the anonymous lifetime #2 defined on the body at 8:18... 8 --> $DIR/regions-infer-call-3.rs:8:18 9 | 10LL | let z = with(|y| { select(x, y) }); 11 | ^^^^^^^^^^^^^^^^^^^^ 12note: ...so that reference does not outlive borrowed content 13 --> $DIR/regions-infer-call-3.rs:8:34 14 | 15LL | let z = with(|y| { select(x, y) }); 16 | ^ 17note: but, the lifetime must be valid for the call at 8:13... 18 --> $DIR/regions-infer-call-3.rs:8:13 19 | 20LL | let z = with(|y| { select(x, y) }); 21 | ^^^^^^^^^^^^^^^^^^^^^^^^^^ 22note: ...so type `&isize` of expression is valid during the expression 23 --> $DIR/regions-infer-call-3.rs:8:13 24 | 25LL | let z = with(|y| { select(x, y) }); 26 | ^^^^^^^^^^^^^^^^^^^^^^^^^^ 27 28error: aborting due to previous error 29 30For more information about this error, try `rustc --explain E0495`.