Title: [233070] trunk/Source/_javascript_Core
Revision
233070
Author
[email protected]
Date
2018-06-21 20:01:52 -0700 (Thu, 21 Jun 2018)

Log Message

WebKit (_javascript_Core) compilation error with Clang ≥ 6.
https://bugs.webkit.org/show_bug.cgi?id=185947
<rdar://problem/40131933>

Reviewed by Saam Barati.

Newer Clang versions (due to C++17 support) is not happy with how I implemented
conversions between CodeLocation types.  We'll fix this by adding a conversion
operator for converting between CodeLocation types.

* assembler/CodeLocation.h:
(JSC::CodeLocationCommon::operator T):

Modified Paths

Diff

Modified: trunk/Source/_javascript_Core/ChangeLog (233069 => 233070)


--- trunk/Source/_javascript_Core/ChangeLog	2018-06-22 00:21:11 UTC (rev 233069)
+++ trunk/Source/_javascript_Core/ChangeLog	2018-06-22 03:01:52 UTC (rev 233070)
@@ -1,3 +1,18 @@
+2018-06-21  Mark Lam  <[email protected]>
+
+        WebKit (_javascript_Core) compilation error with Clang ≥ 6.
+        https://bugs.webkit.org/show_bug.cgi?id=185947
+        <rdar://problem/40131933>
+
+        Reviewed by Saam Barati.
+
+        Newer Clang versions (due to C++17 support) is not happy with how I implemented
+        conversions between CodeLocation types.  We'll fix this by adding a conversion
+        operator for converting between CodeLocation types.
+
+        * assembler/CodeLocation.h:
+        (JSC::CodeLocationCommon::operator T):
+
 2018-06-21  Saam Barati  <[email protected]>
 
         Do some CoW cleanup

Modified: trunk/Source/_javascript_Core/assembler/CodeLocation.h (233069 => 233070)


--- trunk/Source/_javascript_Core/assembler/CodeLocation.h	2018-06-22 00:21:11 UTC (rev 233069)
+++ trunk/Source/_javascript_Core/assembler/CodeLocation.h	2018-06-22 03:01:52 UTC (rev 233070)
@@ -71,6 +71,12 @@
     template<typename T = void*>
     T dataLocation() const { return Base::template dataLocation<T>(); }
 
+    template<typename T, typename = std::enable_if_t<std::is_base_of<CodeLocationCommon<tag>, T>::value>>
+    operator T()
+    {
+        return T(MacroAssemblerCodePtr<tag>::createFromExecutableAddress(this->executableAddress()));
+    }
+
 protected:
     CodeLocationCommon()
     {
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to