Source/JavaScriptCore:
authorfpizlo@apple.com <fpizlo@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 9 Mar 2017 21:18:25 +0000 (21:18 +0000)
committerfpizlo@apple.com <fpizlo@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 9 Mar 2017 21:18:25 +0000 (21:18 +0000)
commitfac7f89467cee88b234ca970c5672fc4dc2c474b
treed28790250a4bad80fd8dbc6b29024159ef19e5e0
parent36b06864f0dc583cd9bda7504ce339095870a39e
Source/JavaScriptCore:
std::isnan/isinf should work with WTF time classes
https://bugs.webkit.org/show_bug.cgi?id=164991

Reviewed by Darin Adler.

Changes AtomicsObject to use std::isnan() instead of operator== to detect NaN.

* runtime/AtomicsObject.cpp:
(JSC::atomicsFuncWait):

Source/WTF:
std::isnan/isinf/isfinite should work with WTF time classes
https://bugs.webkit.org/show_bug.cgi?id=164991

Reviewed by Darin Adler.

The consensus view (see comments in https://bugs.webkit.org/show_bug.cgi?id=152045) of how
to check if something is NaN is to use std::isnan(). To be able to do that for time
classes, they need to provide their own isnan() overhload. This also provides isinf()
overloads.

* wtf/MonotonicTime.h:
(std::isnan):
(std::isinf):
* wtf/Seconds.h:
(std::isnan):
(std::isinf):
* wtf/TimeWithDynamicClockType.h:
(std::isnan):
(std::isinf):
* wtf/WallTime.h:
(std::isnan):
(std::isinf):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@213659 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/JavaScriptCore/ChangeLog
Source/JavaScriptCore/runtime/AtomicsObject.cpp
Source/WTF/ChangeLog
Source/WTF/wtf/MonotonicTime.h
Source/WTF/wtf/Seconds.h
Source/WTF/wtf/TimeWithDynamicClockType.h
Source/WTF/wtf/WallTime.h