diff options
author | yang-g <yangg@google.com> | 2015-08-26 22:04:30 -0700 |
---|---|---|
committer | yang-g <yangg@google.com> | 2015-08-26 22:04:30 -0700 |
commit | 0d9f81f741b33e23941db435b9ba7a9ed37adaec (patch) | |
tree | 8396780e126a8db360700b182ed2722eef2527a9 /test | |
parent | 967caaada09ab68acb6242311549012f1a07bbff (diff) |
minor fixes
Diffstat (limited to 'test')
-rw-r--r-- | test/cpp/util/string_ref_test.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/test/cpp/util/string_ref_test.cc b/test/cpp/util/string_ref_test.cc index c4ca4fce84..465072d43e 100644 --- a/test/cpp/util/string_ref_test.cc +++ b/test/cpp/util/string_ref_test.cc @@ -100,8 +100,8 @@ TEST_F(StringRefTest, Assignment) { TEST_F(StringRefTest, Iterator) { string_ref s(kTestString); size_t i = 0; - for (char c : s) { - EXPECT_EQ(kTestString[i++], c); + for (auto it = s.cbegin(); it != s.cend(); ++it) { + EXPECT_EQ(kTestString[i++], *it); } EXPECT_EQ(strlen(kTestString), i); } |