diff options
author | 2016-07-13 13:34:46 -0700 | |
---|---|---|
committer | 2016-07-13 13:34:46 -0700 | |
commit | 0d2c234e447d54110ee080d9f54ab347944393b0 (patch) | |
tree | d3f1195bf3b81eca2a509611bcf51b0b3a754269 /include | |
parent | 05c73b7ed5b73a55cbecf7f787a35fcc0e84e983 (diff) |
Fix SkFixedDiv macro
Previously, the macro won't pass the unit test that I just added in this
CL.
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2149733002
Review-Url: https://codereview.chromium.org/2149733002
Diffstat (limited to 'include')
-rw-r--r-- | include/private/SkFixed.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/private/SkFixed.h b/include/private/SkFixed.h index 640f0e7ea3..be3bb5d604 100644 --- a/include/private/SkFixed.h +++ b/include/private/SkFixed.h @@ -78,7 +78,7 @@ typedef int32_t SkFixed; // The divide may exceed 32 bits. Clamp to a signed 32 bit result. #define SkFixedDiv(numer, denom) \ - SkToS32(SkTPin<int64_t>((SkLeftShift((int64_t)numer, 16) / denom), SK_MinS32, SK_MaxS32)) + SkToS32(SkTPin<int64_t>((SkLeftShift((int64_t)(numer), 16) / (denom)), SK_MinS32, SK_MaxS32)) ////////////////////////////////////////////////////////////////////////////////////////////////////// // Now look for ASM overrides for our portable versions (should consider putting this in its own file) |