From f08d1d0ce19c72bb911f059dcf916cf99a0a2467 Mon Sep 17 00:00:00 2001 From: Ben Wagner Date: Mon, 18 Jun 2018 15:11:00 -0400 Subject: Stop using SkTSwap. Use std::swap instead. It does not appear that any external user specializes SkTSwap, but some may still use it. This removes all use in Skia so that SkTSwap can later be removed in a smaller CL. After that the include can be removed from SkTypes.h. Change-Id: If03d4ee07dbecda961aa9f0dc34d171ef5168753 Reviewed-on: https://skia-review.googlesource.com/135578 Reviewed-by: Hal Canary Reviewed-by: Mike Klein Commit-Queue: Ben Wagner --- tests/PathOpsQuadLineIntersectionThreadedTest.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'tests/PathOpsQuadLineIntersectionThreadedTest.cpp') diff --git a/tests/PathOpsQuadLineIntersectionThreadedTest.cpp b/tests/PathOpsQuadLineIntersectionThreadedTest.cpp index a82ac28fde..c61589469f 100644 --- a/tests/PathOpsQuadLineIntersectionThreadedTest.cpp +++ b/tests/PathOpsQuadLineIntersectionThreadedTest.cpp @@ -13,6 +13,8 @@ #include "SkReduceOrder.h" #include "SkString.h" +#include + static int doIntersect(SkIntersections& intersections, const SkDQuad& quad, const SkDLine& line, bool& flipped) { int result; @@ -22,7 +24,8 @@ static int doIntersect(SkIntersections& intersections, const SkDQuad& quad, cons double bottom = line[1].fY; flipped = top > bottom; if (flipped) { - SkTSwap(top, bottom); + using std::swap; + swap(top, bottom); } result = intersections.vertical(quad, top, bottom, line[0].fX, flipped); } else if (line[0].fY == line[1].fY) { @@ -30,7 +33,8 @@ static int doIntersect(SkIntersections& intersections, const SkDQuad& quad, cons double right = line[1].fX; flipped = left > right; if (flipped) { - SkTSwap(left, right); + using std::swap; + swap(left, right); } result = intersections.horizontal(quad, left, right, line[0].fY, flipped); } else { -- cgit v1.2.3