summaryrefslogtreecommitdiff
path: root/Source/JavaScriptCore/runtime/JSCell.h
diff options
context:
space:
mode:
Diffstat (limited to 'Source/JavaScriptCore/runtime/JSCell.h')
-rw-r--r--Source/JavaScriptCore/runtime/JSCell.h11
1 files changed, 2 insertions, 9 deletions
diff --git a/Source/JavaScriptCore/runtime/JSCell.h b/Source/JavaScriptCore/runtime/JSCell.h
index 94f08f31b..d6abcba99 100644
--- a/Source/JavaScriptCore/runtime/JSCell.h
+++ b/Source/JavaScriptCore/runtime/JSCell.h
@@ -33,6 +33,7 @@
#include "SlotVisitorInlineMethods.h"
#include "WriteBarrier.h"
#include <wtf/Noncopyable.h>
+#include <wtf/TypeTraits.h>
namespace JSC {
@@ -308,18 +309,10 @@ namespace JSC {
return isCell() ? asCell()->toObject(exec, globalObject) : toObjectSlowCase(exec, globalObject);
}
-#if COMPILER(CLANG)
template<class T>
struct NeedsDestructor {
- static const bool value = !__has_trivial_destructor(T);
+ static const bool value = !WTF::HasTrivialDestructor<T>::value;
};
-#else
- // Write manual specializations for this struct template if you care about non-clang compilers.
- template<class T>
- struct NeedsDestructor {
- static const bool value = true;
- };
-#endif
template<typename T>
void* allocateCell(Heap& heap)