|
| 1 | +warning: not reporting region error due to -Znll |
| 2 | + --> $DIR/projection-no-regions-closure.rs:36:31 |
| 3 | + | |
| 4 | +36 | with_signature(x, |mut y| Box::new(y.next())) |
| 5 | + | ^^^^^^^^^^^^^^^^^^ |
| 6 | + |
| 7 | +warning: not reporting region error due to -Znll |
| 8 | + --> $DIR/projection-no-regions-closure.rs:54:31 |
| 9 | + | |
| 10 | +54 | with_signature(x, |mut y| Box::new(y.next())) |
| 11 | + | ^^^^^^^^^^^^^^^^^^ |
| 12 | + |
| 13 | +note: External requirements |
| 14 | + --> $DIR/projection-no-regions-closure.rs:36:23 |
| 15 | + | |
| 16 | +36 | with_signature(x, |mut y| Box::new(y.next())) |
| 17 | + | ^^^^^^^^^^^^^^^^^^^^^^^^^^ |
| 18 | + | |
| 19 | + = note: defining type: DefId(0/1:15 ~ projection_no_regions_closure[317d]::no_region[0]::{{closure}}[0]) with closure substs [ |
| 20 | + '_#1r, |
| 21 | + T, |
| 22 | + i32, |
| 23 | + extern "rust-call" fn((std::boxed::Box<T>,)) -> std::boxed::Box<Anything + '_#2r> |
| 24 | + ] |
| 25 | + = note: number of external vids: 3 |
| 26 | + = note: where <T as std::iter::Iterator>::Item: '_#2r |
| 27 | + |
| 28 | +note: External requirements |
| 29 | + --> $DIR/projection-no-regions-closure.rs:46:23 |
| 30 | + | |
| 31 | +46 | with_signature(x, |mut y| Box::new(y.next())) |
| 32 | + | ^^^^^^^^^^^^^^^^^^^^^^^^^^ |
| 33 | + | |
| 34 | + = note: defining type: DefId(0/1:18 ~ projection_no_regions_closure[317d]::correct_region[0]::{{closure}}[0]) with closure substs [ |
| 35 | + '_#1r, |
| 36 | + T, |
| 37 | + i32, |
| 38 | + extern "rust-call" fn((std::boxed::Box<T>,)) -> std::boxed::Box<Anything + '_#2r> |
| 39 | + ] |
| 40 | + = note: number of external vids: 3 |
| 41 | + = note: where <T as std::iter::Iterator>::Item: '_#2r |
| 42 | + |
| 43 | +note: External requirements |
| 44 | + --> $DIR/projection-no-regions-closure.rs:54:23 |
| 45 | + | |
| 46 | +54 | with_signature(x, |mut y| Box::new(y.next())) |
| 47 | + | ^^^^^^^^^^^^^^^^^^^^^^^^^^ |
| 48 | + | |
| 49 | + = note: defining type: DefId(0/1:22 ~ projection_no_regions_closure[317d]::wrong_region[0]::{{closure}}[0]) with closure substs [ |
| 50 | + '_#1r, |
| 51 | + '_#2r, |
| 52 | + T, |
| 53 | + i32, |
| 54 | + extern "rust-call" fn((std::boxed::Box<T>,)) -> std::boxed::Box<Anything + '_#3r> |
| 55 | + ] |
| 56 | + = note: number of external vids: 4 |
| 57 | + = note: where <T as std::iter::Iterator>::Item: '_#3r |
| 58 | + |
| 59 | +note: External requirements |
| 60 | + --> $DIR/projection-no-regions-closure.rs:65:23 |
| 61 | + | |
| 62 | +65 | with_signature(x, |mut y| Box::new(y.next())) |
| 63 | + | ^^^^^^^^^^^^^^^^^^^^^^^^^^ |
| 64 | + | |
| 65 | + = note: defining type: DefId(0/1:26 ~ projection_no_regions_closure[317d]::outlives_region[0]::{{closure}}[0]) with closure substs [ |
| 66 | + '_#1r, |
| 67 | + '_#2r, |
| 68 | + T, |
| 69 | + i32, |
| 70 | + extern "rust-call" fn((std::boxed::Box<T>,)) -> std::boxed::Box<Anything + '_#3r> |
| 71 | + ] |
| 72 | + = note: number of external vids: 4 |
| 73 | + = note: where <T as std::iter::Iterator>::Item: '_#3r |
| 74 | + |
| 75 | +error: failed type test: TypeTest { generic_kind: ProjectionTy { substs: Slice([T]), item_def_id: DefId(2/0:1697 ~ core[2633]::iter[0]::iterator[0]::Iterator[0]::Item[0]) }, lower_bound: '_#4r, point: bb0[5], span: $DIR/projection-no-regions-closure.rs:36:23: 36:49, test: IsOutlivedByAnyRegionIn(['_#2r]) } |
| 76 | + --> $DIR/projection-no-regions-closure.rs:36:23 |
| 77 | + | |
| 78 | +36 | with_signature(x, |mut y| Box::new(y.next())) |
| 79 | + | ^^^^^^^^^^^^^^^^^^^^^^^^^^ |
| 80 | + |
| 81 | +note: No external requirements |
| 82 | + --> $DIR/projection-no-regions-closure.rs:32:1 |
| 83 | + | |
| 84 | +32 | / fn no_region<'a, T>(x: Box<T>) -> Box<dyn Anything + 'a> |
| 85 | +33 | | where |
| 86 | +34 | | T: Iterator, |
| 87 | +35 | | { |
| 88 | +... | |
| 89 | +38 | | //~| ERROR failed type test |
| 90 | +39 | | } |
| 91 | + | |_^ |
| 92 | + | |
| 93 | + = note: defining type: DefId(0/0:6 ~ projection_no_regions_closure[317d]::no_region[0]) with substs [ |
| 94 | + '_#1r, |
| 95 | + T |
| 96 | + ] |
| 97 | + |
| 98 | +note: No external requirements |
| 99 | + --> $DIR/projection-no-regions-closure.rs:42:1 |
| 100 | + | |
| 101 | +42 | / fn correct_region<'a, T>(x: Box<T>) -> Box<dyn Anything + 'a> |
| 102 | +43 | | where |
| 103 | +44 | | T: 'a + Iterator, |
| 104 | +45 | | { |
| 105 | +46 | | with_signature(x, |mut y| Box::new(y.next())) |
| 106 | +47 | | } |
| 107 | + | |_^ |
| 108 | + | |
| 109 | + = note: defining type: DefId(0/0:7 ~ projection_no_regions_closure[317d]::correct_region[0]) with substs [ |
| 110 | + '_#1r, |
| 111 | + T |
| 112 | + ] |
| 113 | + |
| 114 | +error: failed type test: TypeTest { generic_kind: ProjectionTy { substs: Slice([T]), item_def_id: DefId(2/0:1697 ~ core[2633]::iter[0]::iterator[0]::Iterator[0]::Item[0]) }, lower_bound: '_#6r, point: bb0[5], span: $DIR/projection-no-regions-closure.rs:54:23: 54:49, test: IsOutlivedByAnyRegionIn(['_#2r, '_#3r]) } |
| 115 | + --> $DIR/projection-no-regions-closure.rs:54:23 |
| 116 | + | |
| 117 | +54 | with_signature(x, |mut y| Box::new(y.next())) |
| 118 | + | ^^^^^^^^^^^^^^^^^^^^^^^^^^ |
| 119 | + |
| 120 | +note: No external requirements |
| 121 | + --> $DIR/projection-no-regions-closure.rs:50:1 |
| 122 | + | |
| 123 | +50 | / fn wrong_region<'a, 'b, T>(x: Box<T>) -> Box<dyn Anything + 'a> |
| 124 | +51 | | where |
| 125 | +52 | | T: 'b + Iterator, |
| 126 | +53 | | { |
| 127 | +... | |
| 128 | +56 | | //~| ERROR failed type test |
| 129 | +57 | | } |
| 130 | + | |_^ |
| 131 | + | |
| 132 | + = note: defining type: DefId(0/0:8 ~ projection_no_regions_closure[317d]::wrong_region[0]) with substs [ |
| 133 | + '_#1r, |
| 134 | + '_#2r, |
| 135 | + T |
| 136 | + ] |
| 137 | + |
| 138 | +note: No external requirements |
| 139 | + --> $DIR/projection-no-regions-closure.rs:60:1 |
| 140 | + | |
| 141 | +60 | / fn outlives_region<'a, 'b, T>(x: Box<T>) -> Box<dyn Anything + 'a> |
| 142 | +61 | | where |
| 143 | +62 | | T: 'b + Iterator, |
| 144 | +63 | | 'b: 'a, |
| 145 | +64 | | { |
| 146 | +65 | | with_signature(x, |mut y| Box::new(y.next())) |
| 147 | +66 | | } |
| 148 | + | |_^ |
| 149 | + | |
| 150 | + = note: defining type: DefId(0/0:9 ~ projection_no_regions_closure[317d]::outlives_region[0]) with substs [ |
| 151 | + '_#1r, |
| 152 | + '_#2r, |
| 153 | + T |
| 154 | + ] |
| 155 | + |
| 156 | +error: aborting due to 2 previous errors |
| 157 | + |
0 commit comments