11note: no external requirements
22 --> $DIR/propagate-approximated-shorter-to-static-comparing-against-free.rs:21:15
33 |
4- LL | foo(cell, |cell_a, cell_x| {
5- | _______________^
6- LL | | cell_a.set(cell_x.get()); // forces 'x: 'a, error in closure
7- LL | |
8- LL | | })
9- | |_____^
4+ LL | foo(cell, |cell_a, cell_x| {
5+ | ^^^^^^^^^^^^^^^^
106 |
117 = note: defining type: case1::{closure#0} with closure substs [
128 i32,
@@ -27,25 +23,16 @@ LL | cell_a.set(cell_x.get()); // forces 'x: 'a, error in closure
2723note: no external requirements
2824 --> $DIR/propagate-approximated-shorter-to-static-comparing-against-free.rs:18:1
2925 |
30- LL | / fn case1() {
31- LL | | let a = 0;
32- LL | | let cell = Cell::new(&a);
33- LL | | foo(cell, |cell_a, cell_x| {
34- ... |
35- LL | | })
36- LL | | }
37- | |_^
26+ LL | fn case1() {
27+ | ^^^^^^^^^^
3828 |
3929 = note: defining type: case1
4030
4131note: external requirements
4232 --> $DIR/propagate-approximated-shorter-to-static-comparing-against-free.rs:35:15
4333 |
44- LL | foo(cell, |cell_a, cell_x| {
45- | _______________^
46- LL | | cell_x.set(cell_a.get()); // forces 'a: 'x, implies 'a = 'static -> borrow error
47- LL | | })
48- | |_____^
34+ LL | foo(cell, |cell_a, cell_x| {
35+ | ^^^^^^^^^^^^^^^^
4936 |
5037 = note: defining type: case2::{closure#0} with closure substs [
5138 i32,
@@ -58,14 +45,8 @@ LL | | })
5845note: no external requirements
5946 --> $DIR/propagate-approximated-shorter-to-static-comparing-against-free.rs:28:1
6047 |
61- LL | / fn case2() {
62- LL | | let a = 0;
63- LL | | let cell = Cell::new(&a);
64- LL | |
65- ... |
66- LL | | })
67- LL | | }
68- | |_^
48+ LL | fn case2() {
49+ | ^^^^^^^^^^
6950 |
7051 = note: defining type: case2
7152
0 commit comments