From aa97a84404c7505738713a4c19b42347c7daef9e Mon Sep 17 00:00:00 2001 From: djsollen Date: Fri, 22 Jan 2016 06:50:25 -0800 Subject: Revert of Consolidate SK_CRASH and sk_throw into SK_ABORT (patchset #5 id:80001 of https://codereview.chromium.org/1610823002/ ) Reason for revert: Chrome is calling SK_CRASH Original issue's description: > Consolidate SK_CRASH and sk_throw into SK_ABORT > GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1610823002 > > Committed: https://skia.googlesource.com/skia/+/4c5cd7d527ed29aabfa72aa47b23a4496eeda357 TBR=reed@google.com # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true Review URL: https://codereview.chromium.org/1620333002 --- tests/PathOpsCubicLineIntersectionIdeas.cpp | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'tests/PathOpsCubicLineIntersectionIdeas.cpp') diff --git a/tests/PathOpsCubicLineIntersectionIdeas.cpp b/tests/PathOpsCubicLineIntersectionIdeas.cpp index b23dd0ceaf..6aec8b148a 100644 --- a/tests/PathOpsCubicLineIntersectionIdeas.cpp +++ b/tests/PathOpsCubicLineIntersectionIdeas.cpp @@ -194,13 +194,13 @@ DEF_TEST(PathOpsCubicLineRoots, reporter) { if (realRoots == 3) { smallest = SkTMin(smallest, allRoots[2]); } - SkASSERT_RELEASE(smallest < 0); - SkASSERT_RELEASE(smallest >= -1); + SK_ALWAYSBREAK(smallest < 0); + SK_ALWAYSBREAK(smallest >= -1); largeBits = 0; } else { frexp(largest, &largeBits); - SkASSERT_RELEASE(largeBits >= 0); - SkASSERT_RELEASE(largeBits < 256); + SK_ALWAYSBREAK(largeBits >= 0); + SK_ALWAYSBREAK(largeBits < 256); } double step = 1e-6; if (largeBits > 21) { @@ -222,7 +222,7 @@ DEF_TEST(PathOpsCubicLineRoots, reporter) { break; } step *= 1.5; - SkASSERT_RELEASE(step < 1); + SK_ALWAYSBREAK(step < 1); } while (true); worstStep[largeBits] = SkTMax(worstStep[largeBits], diff); #if 0 @@ -256,11 +256,11 @@ static double testOneFailure(const CubicLineFailures& failure) { double allRoots[3] = {0}, validRoots[3] = {0}; int realRoots = SkDCubic::RootsReal(A, B, C, D, allRoots); int valid = SkDQuad::AddValidTs(allRoots, realRoots, validRoots); - SkASSERT_RELEASE(valid == 1); - SkASSERT_RELEASE(realRoots != 1); + SK_ALWAYSBREAK(valid == 1); + SK_ALWAYSBREAK(realRoots != 1); double t = validRoots[0]; SkDPoint calcPt = cubic.ptAtT(t); - SkASSERT_RELEASE(!calcPt.approximatelyEqual(pt)); + SK_ALWAYSBREAK(!calcPt.approximatelyEqual(pt)); int iters = 0; double newT = binary_search(cubic, 0.1, pt, t, &iters); return newT; @@ -271,7 +271,7 @@ DEF_TEST(PathOpsCubicLineFailures, reporter) { for (int index = 0; index < cubicLineFailuresCount; ++index) { const CubicLineFailures& failure = cubicLineFailures[index]; double newT = testOneFailure(failure); - SkASSERT_RELEASE(newT >= 0); + SK_ALWAYSBREAK(newT >= 0); } } @@ -279,5 +279,5 @@ DEF_TEST(PathOpsCubicLineOneFailure, reporter) { return; // disable for now const CubicLineFailures& failure = cubicLineFailures[1]; double newT = testOneFailure(failure); - SkASSERT_RELEASE(newT >= 0); + SK_ALWAYSBREAK(newT >= 0); } -- cgit v1.2.3