From e5b43c33d8c729022218fe4e8515aea5799f3660 Mon Sep 17 00:00:00 2001 From: Zalathar Date: Sun, 16 Jun 2024 15:51:00 +1000 Subject: [PATCH] coverage: Prefer `Iterator::copied` --- compiler/rustc_mir_transform/src/coverage/graph.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/compiler/rustc_mir_transform/src/coverage/graph.rs b/compiler/rustc_mir_transform/src/coverage/graph.rs index 607cb14f4c3..360dccb240d 100644 --- a/compiler/rustc_mir_transform/src/coverage/graph.rs +++ b/compiler/rustc_mir_transform/src/coverage/graph.rs @@ -216,7 +216,7 @@ impl graph::StartNode for CoverageGraph { impl graph::Successors for CoverageGraph { #[inline] fn successors(&self, node: Self::Node) -> impl Iterator { - self.successors[node].iter().cloned() + self.successors[node].iter().copied() } }