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

Unified Diff: Source/wtf/MathExtras.h

Issue 663993003: Don't calculate a top controls adjustment if pinch viewport size is uninitialized. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Feedback Created 6 years, 2 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 | « Source/web/WebViewImpl.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/wtf/MathExtras.h
diff --git a/Source/wtf/MathExtras.h b/Source/wtf/MathExtras.h
index 030b1defd2d8a42ad5e2f23d93f9abcddc73b348..e95702d2f18fa7431e0d8983580157763db794d6 100644
--- a/Source/wtf/MathExtras.h
+++ b/Source/wtf/MathExtras.h
@@ -353,8 +353,7 @@ template<> inline double defaultMinimumForClamp<double>() { return -std::numeric
// And, finally, the actual function for people to call.
template<typename LimitType, typename ValueType> inline LimitType clampTo(ValueType value, LimitType min = defaultMinimumForClamp<LimitType>(), LimitType max = defaultMaximumForClamp<LimitType>())
{
- // FIXME: Uncomment this after fixing all callsites which violate it.
- // ASSERT(!std::isnan(static_cast<double>(value)));
+ ASSERT(!std::isnan(static_cast<double>(value)));
ASSERT(min <= max); // This also ensures |min| and |max| aren't NaN.
return ClampToHelper<LimitType, ValueType>::clampTo(value, min, max);
}
« no previous file with comments | « Source/web/WebViewImpl.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698