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

Side by Side Diff: tools/gn/err.cc

Issue 610293003: Replace more for loops in GN (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: review Created 6 years, 2 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 unified diff | Download patch
« no previous file with comments | « tools/gn/commands.cc ('k') | tools/gn/function_exec_script.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "tools/gn/err.h" 5 #include "tools/gn/err.h"
6 6
7 #include "base/strings/string_number_conversions.h" 7 #include "base/strings/string_number_conversions.h"
8 #include "base/strings/string_util.h" 8 #include "base/strings/string_util.h"
9 #include "tools/gn/filesystem_utils.h" 9 #include "tools/gn/filesystem_utils.h"
10 #include "tools/gn/input_file.h" 10 #include "tools/gn/input_file.h"
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after
179 OutputString(line + "\n", DECORATION_DIM); 179 OutputString(line + "\n", DECORATION_DIM);
180 OutputHighlighedPosition(location_, ranges_, line.size()); 180 OutputHighlighedPosition(location_, ranges_, line.size());
181 } 181 }
182 } 182 }
183 183
184 // Optional help text. 184 // Optional help text.
185 if (!help_text_.empty()) 185 if (!help_text_.empty())
186 OutputString(help_text_ + "\n"); 186 OutputString(help_text_ + "\n");
187 187
188 // Sub errors. 188 // Sub errors.
189 for (size_t i = 0; i < sub_errs_.size(); i++) 189 for (const auto& sub_err : sub_errs_)
190 sub_errs_[i].InternalPrintToStdout(true); 190 sub_err.InternalPrintToStdout(true);
191 } 191 }
OLDNEW
« no previous file with comments | « tools/gn/commands.cc ('k') | tools/gn/function_exec_script.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698