Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1037)

Unified Diff: test/cctest/compiler/test-control-reducer.cc

Issue 765983002: Clean up node iteration (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix windows build Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/compiler/verifier.cc ('k') | test/cctest/compiler/test-node.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/compiler/test-control-reducer.cc
diff --git a/test/cctest/compiler/test-control-reducer.cc b/test/cctest/compiler/test-control-reducer.cc
index d0103f5644009aaf28f1b99a198efa54512f7a73..03aa50b376df99a8ee00224c868431503c6673a4 100644
--- a/test/cctest/compiler/test-control-reducer.cc
+++ b/test/cctest/compiler/test-control-reducer.cc
@@ -130,11 +130,8 @@ class ControlReducerTester : HandleAndZoneScope {
}
Node* SetSelfReferences(Node* node) {
- Node::Inputs inputs = node->inputs();
- for (Node::Inputs::iterator iter(inputs.begin()); iter != inputs.end();
- ++iter) {
- Node* input = *iter;
- if (input == self) node->ReplaceInput(iter.index(), node);
+ for (Edge edge : node->input_edges()) {
+ if (edge.to() == self) node->ReplaceInput(edge.index(), node);
}
return node;
}
« no previous file with comments | « src/compiler/verifier.cc ('k') | test/cctest/compiler/test-node.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698