Index: components/autofill/core/browser/credit_card.cc |
diff --git a/components/autofill/core/browser/credit_card.cc b/components/autofill/core/browser/credit_card.cc |
index 27700bed98a4589728ba09e5e8371fec137d7a08..7fee52b1686f3ec0c16f6d12b71efb19455df686 100644 |
--- a/components/autofill/core/browser/credit_card.cc |
+++ b/components/autofill/core/browser/credit_card.cc |
@@ -574,9 +574,8 @@ int CreditCard::Compare(const CreditCard& credit_card) const { |
const ServerFieldType types[] = {CREDIT_CARD_NAME_FULL, CREDIT_CARD_NUMBER, |
CREDIT_CARD_EXP_MONTH, |
CREDIT_CARD_EXP_4_DIGIT_YEAR}; |
- for (size_t i = 0; i < arraysize(types); ++i) { |
- int comparison = |
- GetRawInfo(types[i]).compare(credit_card.GetRawInfo(types[i])); |
+ for (const auto& type : types) { |
vabr (Chromium)
2016/10/17 07:40:33
const auto& -> ServerFieldType
jdoerrie
2016/10/17 08:42:27
Done.
|
+ int comparison = GetRawInfo(type).compare(credit_card.GetRawInfo(type)); |
if (comparison != 0) |
return comparison; |
} |