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

Unified Diff: tools/gn/ninja_binary_target_writer.cc

Issue 986113002: tools/gn: Convert for loops to use the new range-based loops in C++11. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: more fixes Created 5 years, 9 months 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
Index: tools/gn/ninja_binary_target_writer.cc
diff --git a/tools/gn/ninja_binary_target_writer.cc b/tools/gn/ninja_binary_target_writer.cc
index e6b0e91d29620033537c53af8e3dcbb824f47952..84b819bcd2394fffa00a2a1c161a65aec9cd3af0 100644
--- a/tools/gn/ninja_binary_target_writer.cc
+++ b/tools/gn/ninja_binary_target_writer.cc
@@ -441,10 +441,9 @@ void NinjaBinaryTargetWriter::WriteOrderOnlyDependencies(
out_ << " ||";
// Non-linkable targets.
- for (size_t i = 0; i < non_linkable_deps.size(); i++) {
+ for (const auto& non_linkable_dep : non_linkable_deps) {
out_ << " ";
- path_output_.WriteFile(
- out_, non_linkable_deps[i]->dependency_output_file());
+ path_output_.WriteFile(out_, non_linkable_dep->dependency_output_file());
}
}
}

Powered by Google App Engine
This is Rietveld 408576698