summaryrefslogtreecommitdiff
path: root/Source/JavaScriptCore/runtime
diff options
context:
space:
mode:
authorKonstantin Tokarev <annulen@yandex.ru>2017-04-06 10:05:55 +0300
committerKonstantin Tokarev <annulen@yandex.ru>2017-04-07 18:17:58 +0000
commit928cd15d3d3ab82734f49eb9d694faf59c3a0c6d (patch)
treeb4ccd30048fc23f59c8f156d6a0d1060b7121f16 /Source/JavaScriptCore/runtime
parentbe770ca621f6463339b7d15be088e1b9acd851e5 (diff)
downloadqtwebkit-928cd15d3d3ab82734f49eb9d694faf59c3a0c6d.tar.gz
Import WebKit commit 342c7c7c069db3ca1d09ae6c5f7d600f9b241778
Change-Id: I8886595114569f61168aed76b23ad7288c5cb34c Reviewed-by: Konstantin Tokarev <annulen@yandex.ru>
Diffstat (limited to 'Source/JavaScriptCore/runtime')
-rw-r--r--Source/JavaScriptCore/runtime/JSGenericTypedArrayView.h2
-rw-r--r--Source/JavaScriptCore/runtime/JSGenericTypedArrayViewConstructor.h12
-rw-r--r--Source/JavaScriptCore/runtime/JSGenericTypedArrayViewPrototype.h14
-rw-r--r--Source/JavaScriptCore/runtime/TypedArrayAdaptors.h1
4 files changed, 27 insertions, 2 deletions
diff --git a/Source/JavaScriptCore/runtime/JSGenericTypedArrayView.h b/Source/JavaScriptCore/runtime/JSGenericTypedArrayView.h
index bd437e4ad..bc323021a 100644
--- a/Source/JavaScriptCore/runtime/JSGenericTypedArrayView.h
+++ b/Source/JavaScriptCore/runtime/JSGenericTypedArrayView.h
@@ -150,7 +150,7 @@ public:
void setIndexQuicklyToDouble(unsigned i, double value)
{
- setIndexQuicklyToNativeValue(i, toNativeFromValue<Adaptor>(value));
+ setIndexQuicklyToNativeValue(i, toNativeFromValue<Adaptor>(jsNumber(value)));
}
void setIndexQuickly(unsigned i, JSValue value)
diff --git a/Source/JavaScriptCore/runtime/JSGenericTypedArrayViewConstructor.h b/Source/JavaScriptCore/runtime/JSGenericTypedArrayViewConstructor.h
index 5590df42e..d89fd034e 100644
--- a/Source/JavaScriptCore/runtime/JSGenericTypedArrayViewConstructor.h
+++ b/Source/JavaScriptCore/runtime/JSGenericTypedArrayViewConstructor.h
@@ -43,7 +43,19 @@ public:
static JSGenericTypedArrayViewConstructor* create(
VM&, JSGlobalObject*, Structure*, JSObject* prototype, const String& name, FunctionExecutable* privateAllocator);
+ // FIXME: We should fix the warnings for extern-template in JSObject template classes: https://bugs.webkit.org/show_bug.cgi?id=161979
+#if COMPILER(CLANG)
+#if __has_warning("-Wundefined-var-template")
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wundefined-var-template"
+#endif
+#endif
DECLARE_INFO;
+#if COMPILER(CLANG)
+#if __has_warning("-Wundefined-var-template")
+#pragma clang diagnostic pop
+#endif
+#endif
static Structure* createStructure(VM&, JSGlobalObject*, JSValue prototype);
diff --git a/Source/JavaScriptCore/runtime/JSGenericTypedArrayViewPrototype.h b/Source/JavaScriptCore/runtime/JSGenericTypedArrayViewPrototype.h
index 7ef77490a..12d381246 100644
--- a/Source/JavaScriptCore/runtime/JSGenericTypedArrayViewPrototype.h
+++ b/Source/JavaScriptCore/runtime/JSGenericTypedArrayViewPrototype.h
@@ -42,8 +42,20 @@ protected:
public:
static JSGenericTypedArrayViewPrototype* create(
VM&, JSGlobalObject*, Structure*);
-
+
+ // FIXME: We should fix the warnings for extern-template in JSObject template classes: https://bugs.webkit.org/show_bug.cgi?id=161979
+#if COMPILER(CLANG)
+#if __has_warning("-Wundefined-var-template")
+#pragma clang diagnostic push
+#pragma clang diagnostic ignored "-Wundefined-var-template"
+#endif
+#endif
DECLARE_INFO;
+#if COMPILER(CLANG)
+#if __has_warning("-Wundefined-var-template")
+#pragma clang diagnostic pop
+#endif
+#endif
static Structure* createStructure(VM&, JSGlobalObject*, JSValue prototype);
};
diff --git a/Source/JavaScriptCore/runtime/TypedArrayAdaptors.h b/Source/JavaScriptCore/runtime/TypedArrayAdaptors.h
index d4dc53557..270e36860 100644
--- a/Source/JavaScriptCore/runtime/TypedArrayAdaptors.h
+++ b/Source/JavaScriptCore/runtime/TypedArrayAdaptors.h
@@ -27,6 +27,7 @@
#define TypedArrayAdaptors_h
#include "JSCJSValue.h"
+#include "MathCommon.h"
#include "TypedArrayType.h"
#include <wtf/MathExtras.h>