diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/core/SkRect.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/include/core/SkRect.h b/include/core/SkRect.h index f4b446c1bd..f221cc880d 100644 --- a/include/core/SkRect.h +++ b/include/core/SkRect.h @@ -336,12 +336,12 @@ struct SK_API SkRect { SkScalar centerX() const { return SkScalarHalf(fLeft + fRight); } SkScalar centerY() const { return SkScalarHalf(fTop + fBottom); } - friend int operator==(const SkRect& a, const SkRect& b) { - return !memcmp(&a, &b, sizeof(a)); + friend bool operator==(const SkRect& a, const SkRect& b) { + return 0 == memcmp(&a, &b, sizeof(a)); } - friend int operator!=(const SkRect& a, const SkRect& b) { - return memcmp(&a, &b, sizeof(a)); + friend bool operator!=(const SkRect& a, const SkRect& b) { + return 0 != memcmp(&a, &b, sizeof(a)); } /** return the 4 points that enclose the rectangle |