Replace explicit iteration with an enhanced for loop
@@ -48,7 +48,6 @@ import java.io.IOException;
import java.io.InputStreamReader;
import java.util.Collections;
import java.util.HashMap;
-import java.util.Iterator;
import java.util.LinkedHashMap;
import java.util.Map;
import java.util.Objects;
@@ -406,9 +405,7 @@ public final class Runfiles implements RunfilesApi {
Map<PathFragment, Artifact> newManifest = new HashMap<>();
outer:
- for (Iterator<Map.Entry<PathFragment, Artifact>> i = workingManifest.entrySet().iterator();
- i.hasNext(); ) {
- Map.Entry<PathFragment, Artifact> entry = i.next();
+ for (Map.Entry<PathFragment, Artifact> entry : workingManifest.entrySet()) {
PathFragment source = entry.getKey();
Artifact symlink = entry.getValue();
// drop nested entries; warn if this changes anything
