Index: include/core/SkTypes.h |
diff --git a/include/core/SkTypes.h b/include/core/SkTypes.h |
index b44df0de485056969550fc0428374f7d25ee6315..6793e4c0fbba82d02855fa0bcdfebcead3b836d0 100644 |
--- a/include/core/SkTypes.h |
+++ b/include/core/SkTypes.h |
@@ -149,8 +149,8 @@ inline void operator delete(void* p) { |
#define SkPARAM(var) |
// unlike SkASSERT, this guy executes its condition in the non-debug build. |
- // It casts to void to allow use with functions declared with SK_WARN_RESULT_UNUSED. |
- #define SkAssertResult(cond) (void)(cond) |
+ // The if is present so that this can be used with functions marked SK_WARN_UNUSED_RESULT. |
+ #define SkAssertResult(cond) if (cond) {} do {} while(false) |
#endif |
// Legacy macro names for SK_ABORT |