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

Unified Diff: ui/gfx/codec/jpeg_codec_unittest.cc

Issue 6602049: Pure pedantry: Replace all ".size() == 0" with ".empty()". (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 10 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: ui/gfx/codec/jpeg_codec_unittest.cc
diff --git a/ui/gfx/codec/jpeg_codec_unittest.cc b/ui/gfx/codec/jpeg_codec_unittest.cc
index ca8335f530fcff82e9226fcf1238e887bccfbe68..7a8756a23958524b10659be126d2e737b1e62680 100644
--- a/ui/gfx/codec/jpeg_codec_unittest.cc
+++ b/ui/gfx/codec/jpeg_codec_unittest.cc
@@ -76,7 +76,7 @@ static double AveragePixelDelta(const std::vector<unsigned char>& a,
// if the sizes are different, say the average difference is the maximum
if (a.size() != b.size())
return 255.0;
- if (a.size() == 0)
+ if (a.empty())
return 0; // prevent divide by 0 below
double acc = 0.0;

Powered by Google App Engine
This is Rietveld 408576698