Title: [123906] trunk
- Revision
- 123906
- Author
- jer.no...@apple.com
- Date
- 2012-07-27 12:30:11 -0700 (Fri, 27 Jul 2012)
Log Message
Unreviewed build fix.
Source/WTF:
Use MathExtras.h and the non std:: versions of isnan and signbit.
* wtf/MediaTime.cpp:
(WTF::MediaTime::createWithFloat):
(WTF::MediaTime::createWithDouble):
Tools:
Wrap MSVC-specific fixes is a COMPILER() check, not a PLATFORM() check.
* TestWebKitAPI/Tests/WTF/MediaTime.cpp:
Modified Paths
Diff
Modified: trunk/Source/WTF/ChangeLog (123905 => 123906)
--- trunk/Source/WTF/ChangeLog 2012-07-27 19:29:03 UTC (rev 123905)
+++ trunk/Source/WTF/ChangeLog 2012-07-27 19:30:11 UTC (rev 123906)
@@ -1,5 +1,15 @@
2012-07-27 Jer Noble <jer.no...@apple.com>
+ Unreviewed build fix.
+
+ Use MathExtras.h and the non std:: versions of isnan and signbit.
+
+ * wtf/MediaTime.cpp:
+ (WTF::MediaTime::createWithFloat):
+ (WTF::MediaTime::createWithDouble):
+
+2012-07-27 Jer Noble <jer.no...@apple.com>
+
Support a rational time class for use by media elements.
https://bugs.webkit.org/show_bug.cgi?id=88787
Modified: trunk/Source/WTF/wtf/MediaTime.cpp (123905 => 123906)
--- trunk/Source/WTF/wtf/MediaTime.cpp 2012-07-27 19:29:03 UTC (rev 123905)
+++ trunk/Source/WTF/wtf/MediaTime.cpp 2012-07-27 19:30:11 UTC (rev 123906)
@@ -31,15 +31,8 @@
#include <algorithm>
#include <wtf/CheckedArithmetic.h>
+#include <wtf/MathExtras.h>
-#if PLATFORM(WIN)
-// Work around Visual Studio 2008's lack of an isinf or signbit method in STL.
-namespace std {
- static bool isinf(double number) { return !_finite(number) && !_isnan(number); }
- static int signbit(double number) { return number < 0; }
-}
-#endif
-
using namespace std;
namespace WTF {
@@ -90,8 +83,8 @@
{
if (floatTime != floatTime)
return invalidTime();
- if (std::isinf(floatTime))
- return std::signbit(floatTime) ? negativeInfiniteTime() : positiveInfiniteTime();
+ if (isinf(floatTime))
+ return signbit(floatTime) ? negativeInfiniteTime() : positiveInfiniteTime();
if (floatTime > numeric_limits<int64_t>::max())
return positiveInfiniteTime();
if (floatTime < numeric_limits<int64_t>::min())
@@ -106,8 +99,8 @@
{
if (doubleTime != doubleTime)
return invalidTime();
- if (std::isinf(doubleTime))
- return std::signbit(doubleTime) ? negativeInfiniteTime() : positiveInfiniteTime();
+ if (isinf(doubleTime))
+ return signbit(doubleTime) ? negativeInfiniteTime() : positiveInfiniteTime();
if (doubleTime > numeric_limits<int64_t>::max())
return positiveInfiniteTime();
if (doubleTime < numeric_limits<int64_t>::min())
Modified: trunk/Tools/ChangeLog (123905 => 123906)
--- trunk/Tools/ChangeLog 2012-07-27 19:29:03 UTC (rev 123905)
+++ trunk/Tools/ChangeLog 2012-07-27 19:30:11 UTC (rev 123906)
@@ -1,3 +1,11 @@
+2012-07-27 Jer Noble <jer.no...@apple.com>
+
+ Unreviewed build fix.
+
+ Wrap MSVC-specific fixes is a COMPILER() check, not a PLATFORM() check.
+
+ * TestWebKitAPI/Tests/WTF/MediaTime.cpp:
+
2012-07-27 Xianzhu Wang <wangxian...@chromium.org>
[Chromium-Android] NRWT better handling of DRT deadlocks and crashes
Modified: trunk/Tools/TestWebKitAPI/Tests/WTF/MediaTime.cpp (123905 => 123906)
--- trunk/Tools/TestWebKitAPI/Tests/WTF/MediaTime.cpp 2012-07-27 19:29:03 UTC (rev 123905)
+++ trunk/Tools/TestWebKitAPI/Tests/WTF/MediaTime.cpp 2012-07-27 19:30:11 UTC (rev 123906)
@@ -36,7 +36,7 @@
using namespace std;
-#if PLATFORM(WIN)
+#if COMPILER(MSVC)
// Work around Visual Studio 2008's lack of an INFINITY or NAN definition.
#include <limits>
#if !defined(INFINITY)
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
http://lists.webkit.org/mailman/listinfo/webkit-changes