Title: [96677] trunk/Source/_javascript_Core
Revision
96677
Author
gga...@apple.com
Date
2011-10-04 22:02:57 -0700 (Tue, 04 Oct 2011)

Log Message

Build fix.

* jit/JITStubs.cpp:
(JSC::DEFINE_STUB_FUNCTION): Use an explicit cast when shortening.

Modified Paths

Diff

Modified: trunk/Source/_javascript_Core/ChangeLog (96676 => 96677)


--- trunk/Source/_javascript_Core/ChangeLog	2011-10-05 04:56:08 UTC (rev 96676)
+++ trunk/Source/_javascript_Core/ChangeLog	2011-10-05 05:02:57 UTC (rev 96677)
@@ -1,3 +1,10 @@
+2011-10-04  Geoffrey Garen  <gga...@apple.com>
+
+        Build fix.
+
+        * jit/JITStubs.cpp:
+        (JSC::DEFINE_STUB_FUNCTION): Use an explicit cast when shortening.
+
 2011-10-04  Mark Hahnenberg  <mhahnenb...@apple.com>
 
         Add static ClassInfo structs to classes that override JSCell::getCallData

Modified: trunk/Source/_javascript_Core/jit/JITStubs.cpp (96676 => 96677)


--- trunk/Source/_javascript_Core/jit/JITStubs.cpp	2011-10-05 04:56:08 UTC (rev 96676)
+++ trunk/Source/_javascript_Core/jit/JITStubs.cpp	2011-10-05 05:02:57 UTC (rev 96677)
@@ -3656,12 +3656,8 @@
 
     if (scrutinee.isInt32())
         return codeBlock->immediateSwitchJumpTable(tableIndex).ctiForValue(scrutinee.asInt32()).executableAddress();
-    if (scrutinee.isDouble()) {
-        double value = scrutinee.asDouble();
-        int32_t int32Value = value;
-        if (int32Value == value)
-            return codeBlock->immediateSwitchJumpTable(tableIndex).ctiForValue(int32Value).executableAddress();
-    }
+    if (scrutinee.isDouble() && scrutinee.asDouble() == static_cast<int32_t>(scrutinee.asDouble()))
+            return codeBlock->immediateSwitchJumpTable(tableIndex).ctiForValue(static_cast<int32_t>(scrutinee.asDouble())).executableAddress();
     return codeBlock->immediateSwitchJumpTable(tableIndex).ctiDefault.executableAddress();
 }
 
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to