Skip to content

Commit 1d6723a

Browse files
committed
Use for_each instead of fold.
1 parent 3082028 commit 1d6723a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

compiler/rustc_mir_dataflow/src/points.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ where
135135
) {
136136
let point = self.elements.point_from_location(location);
137137
// Use internal iterator manually as it is much more efficient.
138-
state.iter().fold((), |(), node| {
138+
state.iter().for_each(|node| {
139139
self.values.insert(node, point);
140140
});
141141
}
@@ -149,7 +149,7 @@ where
149149
) {
150150
let point = self.elements.point_from_location(location);
151151
// Use internal iterator manually as it is much more efficient.
152-
state.iter().fold((), |(), node| {
152+
state.iter().for_each(|node| {
153153
self.values.insert(node, point);
154154
});
155155
}

0 commit comments

Comments
 (0)