File tree 2 files changed +5
-5
lines changed
rustc_mir/src/transform/coverage
2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -461,7 +461,7 @@ impl<'tcx> Body<'tcx> {
461
461
}
462
462
463
463
#[ inline]
464
- pub fn predecessors ( & self ) -> impl std :: ops :: Deref < Target = Predecessors > + ' _ {
464
+ pub fn predecessors ( & self ) -> & Predecessors {
465
465
self . predecessor_cache . compute ( & self . basic_blocks )
466
466
}
467
467
@@ -2815,13 +2815,13 @@ impl<'a, 'b> graph::GraphSuccessors<'b> for Body<'a> {
2815
2815
2816
2816
impl graph:: GraphPredecessors < ' graph > for Body < ' tcx > {
2817
2817
type Item = BasicBlock ;
2818
- type Iter = smallvec :: IntoIter < [ BasicBlock ; 4 ] > ;
2818
+ type Iter = std :: iter :: Copied < std :: slice :: Iter < ' graph , BasicBlock > > ;
2819
2819
}
2820
2820
2821
2821
impl graph:: WithPredecessors for Body < ' tcx > {
2822
2822
#[ inline]
2823
2823
fn predecessors ( & self , node : Self :: Node ) -> <Self as graph:: GraphPredecessors < ' _ > >:: Iter {
2824
- self . predecessors ( ) [ node] . clone ( ) . into_iter ( )
2824
+ self . predecessors ( ) [ node] . iter ( ) . copied ( )
2825
2825
}
2826
2826
}
2827
2827
Original file line number Diff line number Diff line change @@ -269,13 +269,13 @@ impl graph::WithSuccessors for CoverageGraph {
269
269
270
270
impl graph:: GraphPredecessors < ' graph > for CoverageGraph {
271
271
type Item = BasicCoverageBlock ;
272
- type Iter = std:: vec :: IntoIter < BasicCoverageBlock > ;
272
+ type Iter = std:: iter :: Copied < std :: slice :: Iter < ' graph , BasicCoverageBlock > > ;
273
273
}
274
274
275
275
impl graph:: WithPredecessors for CoverageGraph {
276
276
#[ inline]
277
277
fn predecessors ( & self , node : Self :: Node ) -> <Self as graph:: GraphPredecessors < ' _ > >:: Iter {
278
- self . predecessors [ node] . clone ( ) . into_iter ( )
278
+ self . predecessors [ node] . iter ( ) . copied ( )
279
279
}
280
280
}
281
281
You can’t perform that action at this time.
0 commit comments