Title: [246881] trunk/Source/_javascript_Core
- Revision
- 246881
- Author
- annu...@yandex.ru
- Date
- 2019-06-27 08:38:57 -0700 (Thu, 27 Jun 2019)
Log Message
Use JSC_GLIB_API_ENABLED instead of USE(GLIB) as a compile-time check for GLib JSC API
https://bugs.webkit.org/show_bug.cgi?id=199270
Reviewed by Michael Catanzaro.
This change allows building code with enabled USE(GLIB) but without
GLib JSC API.
* heap/Heap.cpp:
(JSC::Heap::releaseDelayedReleasedObjects):
* heap/Heap.h:
* heap/HeapInlines.h:
Modified Paths
Diff
Modified: trunk/Source/_javascript_Core/ChangeLog (246880 => 246881)
--- trunk/Source/_javascript_Core/ChangeLog 2019-06-27 13:45:32 UTC (rev 246880)
+++ trunk/Source/_javascript_Core/ChangeLog 2019-06-27 15:38:57 UTC (rev 246881)
@@ -1,3 +1,18 @@
+2019-06-27 Konstantin Tokarev <annu...@yandex.ru>
+
+ Use JSC_GLIB_API_ENABLED instead of USE(GLIB) as a compile-time check for GLib JSC API
+ https://bugs.webkit.org/show_bug.cgi?id=199270
+
+ Reviewed by Michael Catanzaro.
+
+ This change allows building code with enabled USE(GLIB) but without
+ GLib JSC API.
+
+ * heap/Heap.cpp:
+ (JSC::Heap::releaseDelayedReleasedObjects):
+ * heap/Heap.h:
+ * heap/HeapInlines.h:
+
2019-06-27 Devin Rousso <drou...@apple.com>
Web Inspector: throw an error if console.count/console.countReset is called with an object that throws an error from toString
Modified: trunk/Source/_javascript_Core/heap/Heap.cpp (246880 => 246881)
--- trunk/Source/_javascript_Core/heap/Heap.cpp 2019-06-27 13:45:32 UTC (rev 246880)
+++ trunk/Source/_javascript_Core/heap/Heap.cpp 2019-06-27 15:38:57 UTC (rev 246881)
@@ -96,7 +96,7 @@
#include <wtf/spi/cocoa/objcSPI.h>
#endif
-#if USE(GLIB)
+#ifdef JSC_GLIB_API_ENABLED
#include "JSCGLibWrapperObject.h"
#endif
@@ -477,7 +477,7 @@
void Heap::releaseDelayedReleasedObjects()
{
-#if USE(FOUNDATION) || USE(GLIB)
+#if USE(FOUNDATION) || defined(JSC_GLIB_API_ENABLED)
// We need to guard against the case that releasing an object can create more objects due to the
// release calling into JS. When those JS call(s) exit and all locks are being dropped we end up
// back here and could try to recursively release objects. We guard that with a recursive entry
Modified: trunk/Source/_javascript_Core/heap/Heap.h (246880 => 246881)
--- trunk/Source/_javascript_Core/heap/Heap.h 2019-06-27 13:45:32 UTC (rev 246880)
+++ trunk/Source/_javascript_Core/heap/Heap.h 2019-06-27 15:38:57 UTC (rev 246881)
@@ -86,7 +86,7 @@
class WeakGCMapBase;
struct CurrentThreadState;
-#if USE(GLIB)
+#ifdef JSC_GLIB_API_ENABLED
class JSCGLibWrapperObject;
#endif
@@ -279,7 +279,7 @@
#if USE(FOUNDATION)
template<typename T> void releaseSoon(RetainPtr<T>&&);
#endif
-#if USE(GLIB)
+#ifdef JSC_GLIB_API_ENABLED
void releaseSoon(std::unique_ptr<JSCGLibWrapperObject>&&);
#endif
@@ -664,7 +664,7 @@
Vector<RetainPtr<CFTypeRef>> m_delayedReleaseObjects;
unsigned m_delayedReleaseRecursionCount { 0 };
#endif
-#if USE(GLIB)
+#ifdef JSC_GLIB_API_ENABLED
Vector<std::unique_ptr<JSCGLibWrapperObject>> m_delayedReleaseObjects;
unsigned m_delayedReleaseRecursionCount { 0 };
#endif
Modified: trunk/Source/_javascript_Core/heap/HeapInlines.h (246880 => 246881)
--- trunk/Source/_javascript_Core/heap/HeapInlines.h 2019-06-27 13:45:32 UTC (rev 246880)
+++ trunk/Source/_javascript_Core/heap/HeapInlines.h 2019-06-27 15:38:57 UTC (rev 246881)
@@ -164,7 +164,7 @@
}
#endif
-#if USE(GLIB)
+#ifdef JSC_GLIB_API_ENABLED
inline void Heap::releaseSoon(std::unique_ptr<JSCGLibWrapperObject>&& object)
{
m_delayedReleaseObjects.append(WTFMove(object));
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes