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

Unified Diff: include/private/SkFloatBits.h

Issue 1737363002: fix undefined signed shifts (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: try again on nan Created 4 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
« no previous file with comments | « include/core/SkTypes.h ('k') | src/gpu/effects/GrMatrixConvolutionEffect.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/private/SkFloatBits.h
diff --git a/include/private/SkFloatBits.h b/include/private/SkFloatBits.h
index 3ddb9ef564cfaaf2dd07e9f04bd1ce02b4b39d35..caad342a4a6b82416c782206d6b6beaa79fe3b22 100644
--- a/include/private/SkFloatBits.h
+++ b/include/private/SkFloatBits.h
@@ -32,7 +32,7 @@ static inline int32_t Sk2sComplimentToSignBit(int32_t x) {
// make x positive
x = (x ^ sign) - sign;
// set the sign bit as needed
- x |= sign << 31;
+ x |= SkLeftShift(sign, 31);
return x;
}
« no previous file with comments | « include/core/SkTypes.h ('k') | src/gpu/effects/GrMatrixConvolutionEffect.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698