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

Unified Diff: skia/ext/benchmarking_canvas.cc

Issue 2575533002: SkClipOp is an enum class now (Closed)
Patch Set: Created 4 years 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
« no previous file with comments | « skia/config/SkUserConfig.h ('k') | third_party/WebKit/Source/modules/canvas2d/BaseRenderingContext2D.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: skia/ext/benchmarking_canvas.cc
diff --git a/skia/ext/benchmarking_canvas.cc b/skia/ext/benchmarking_canvas.cc
index e5adc0db7e420fc91829b491e515ca33bc620c80..32e4df0c1489da408746a8f453248679590a6e6c 100644
--- a/skia/ext/benchmarking_canvas.cc
+++ b/skia/ext/benchmarking_canvas.cc
@@ -272,8 +272,10 @@ std::unique_ptr<base::Value> AsValue(SkClipOp op) {
"ReverseDifference",
"Replace"
};
- DCHECK_LT(static_cast<size_t>(op), SK_ARRAY_COUNT(gOpStrings));
- std::unique_ptr<base::StringValue> val(new base::StringValue(gOpStrings[op]));
+ size_t index = static_cast<size_t>(op);
+ DCHECK_LT(index, SK_ARRAY_COUNT(gOpStrings));
+ std::unique_ptr<base::StringValue> val(
+ new base::StringValue(gOpStrings[index]));
return std::move(val);
}
« no previous file with comments | « skia/config/SkUserConfig.h ('k') | third_party/WebKit/Source/modules/canvas2d/BaseRenderingContext2D.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698