fork/rust
git clone https://git.julia.blue/fork/rust
4560ea788cb
1.39.0
1note: External requirements 2 --> $DIR/ty-param-closure-approximate-lower-bound.rs:24:24 3 | 4LL | twice(cell, value, |a, b| invoke(a, b)); 5 | ^^^^^^^^^^^^^^^^^^^ 6 | 7 = note: defining type: DefId(0:20 ~ ty_param_closure_approximate_lower_bound[317d]::generic[0]::{{closure}}[0]) with closure substs [ 8 T, 9 i16, 10 for<'r, 's> extern "rust-call" fn((std::option::Option<std::cell::Cell<&'_#1r &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 'r)) ()>>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 's)) T)), 11 ] 12 = note: number of external vids: 2 13 = note: where T: '_#1r 14 15note: No external requirements 16 --> $DIR/ty-param-closure-approximate-lower-bound.rs:22:1 17 | 18LL | / fn generic<T>(value: T) { 19LL | | let cell = Cell::new(&()); 20LL | | twice(cell, value, |a, b| invoke(a, b)); 21LL | | } 22 | |_^ 23 | 24 = note: defining type: DefId(0:18 ~ ty_param_closure_approximate_lower_bound[317d]::generic[0]) with substs [ 25 T, 26 ] 27 28note: External requirements 29 --> $DIR/ty-param-closure-approximate-lower-bound.rs:29:24 30 | 31LL | twice(cell, value, |a, b| invoke(a, b)); 32 | ^^^^^^^^^^^^^^^^^^^ 33 | 34 = note: defining type: DefId(0:24 ~ ty_param_closure_approximate_lower_bound[317d]::generic_fail[0]::{{closure}}[0]) with closure substs [ 35 T, 36 i16, 37 for<'r, 's> extern "rust-call" fn((std::option::Option<std::cell::Cell<&'_#1r &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 'r)) ()>>, &ReLateBound(DebruijnIndex(0), BrNamed(crate0:DefIndex(0), 's)) T)), 38 ] 39 = note: late-bound region is '_#2r 40 = note: number of external vids: 3 41 = note: where T: '_#1r 42 43note: No external requirements 44 --> $DIR/ty-param-closure-approximate-lower-bound.rs:28:1 45 | 46LL | / fn generic_fail<'a, T>(cell: Cell<&'a ()>, value: T) { 47LL | | twice(cell, value, |a, b| invoke(a, b)); 48LL | | 49LL | | } 50 | |_^ 51 | 52 = note: defining type: DefId(0:21 ~ ty_param_closure_approximate_lower_bound[317d]::generic_fail[0]) with substs [ 53 T, 54 ] 55 56error[E0309]: the parameter type `T` may not live long enough 57 --> $DIR/ty-param-closure-approximate-lower-bound.rs:29:24 58 | 59LL | twice(cell, value, |a, b| invoke(a, b)); 60 | ^^^^^^^^^^^^^^^^^^^ 61 | 62 = help: consider adding an explicit lifetime bound `T: ReFree(DefId(0:21 ~ ty_param_closure_approximate_lower_bound[317d]::generic_fail[0]), BrNamed(crate0:DefIndex(22), 'a))`... 63 64error: aborting due to previous error 65 66For more information about this error, try `rustc --explain E0309`.