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

Unified Diff: src/core/SkScan_AntiPath.cpp

Issue 1661873003: use left-shift macro to fix/avoid undefined behvarior warnings (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 11 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkScan_AntiPath.cpp
diff --git a/src/core/SkScan_AntiPath.cpp b/src/core/SkScan_AntiPath.cpp
index 22bca7a55cf6453a0707e6f7adb21ee065db8dd2..06365c1b93374f3d3ade31cc81735a0b12ad0bc3 100644
--- a/src/core/SkScan_AntiPath.cpp
+++ b/src/core/SkScan_AntiPath.cpp
@@ -703,8 +703,10 @@ void SkScan::AntiFillPath(const SkPath& path, const SkRegion& origClip,
SkIRect superRect, *superClipRect = nullptr;
if (clipRect) {
- superRect.set( clipRect->fLeft << SHIFT, clipRect->fTop << SHIFT,
- clipRect->fRight << SHIFT, clipRect->fBottom << SHIFT);
+ superRect.set(SkLeftShift(clipRect->fLeft, SHIFT),
+ SkLeftShift(clipRect->fTop, SHIFT),
+ SkLeftShift(clipRect->fRight, SHIFT),
+ SkLeftShift(clipRect->fBottom, SHIFT));
superClipRect = &superRect;
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698