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

Unified Diff: components/autofill/core/browser/autofill_merge_unittest.cc

Issue 2417783004: Replace for loops with |arraysize| with for each loops (Closed)
Patch Set: Created 4 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 side-by-side diff with in-line comments
Download patch
Index: components/autofill/core/browser/autofill_merge_unittest.cc
diff --git a/components/autofill/core/browser/autofill_merge_unittest.cc b/components/autofill/core/browser/autofill_merge_unittest.cc
index dfa93142527c1beb8c0671749aad8b99e208bc94..f0ba14067dbc3c5465f4bef183c67f2b7cc772de 100644
--- a/components/autofill/core/browser/autofill_merge_unittest.cc
+++ b/components/autofill/core/browser/autofill_merge_unittest.cc
@@ -91,8 +91,7 @@ std::string SerializeProfiles(const std::vector<AutofillProfile*>& profiles) {
for (size_t i = 0; i < profiles.size(); ++i) {
result += kProfileSeparator;
result += "\n";
- for (size_t j = 0; j < arraysize(kProfileFieldTypes); ++j) {
- ServerFieldType type = kProfileFieldTypes[j];
+ for (const ServerFieldType& type : kProfileFieldTypes) {
base::string16 value = profiles[i]->GetRawInfo(type);
result += AutofillType(type).ToString();
result += kFieldSeparator;

Powered by Google App Engine
This is Rietveld 408576698