Changeset 246881 in webkit


Ignore:
Timestamp:
Jun 27, 2019 8:38:57 AM (5 years ago)
Author:
Konstantin Tokarev
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:
Location:
trunk/Source/JavaScriptCore
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/JavaScriptCore/ChangeLog

    r246876 r246881  
     12019-06-27  Konstantin Tokarev  <annulen@yandex.ru>
     2
     3        Use JSC_GLIB_API_ENABLED instead of USE(GLIB) as a compile-time check for GLib JSC API
     4        https://bugs.webkit.org/show_bug.cgi?id=199270
     5
     6        Reviewed by Michael Catanzaro.
     7
     8        This change allows building code with enabled USE(GLIB) but without
     9        GLib JSC API.
     10
     11        * heap/Heap.cpp:
     12        (JSC::Heap::releaseDelayedReleasedObjects):
     13        * heap/Heap.h:
     14        * heap/HeapInlines.h:
     15
    1162019-06-27  Devin Rousso  <drousso@apple.com>
    217
  • trunk/Source/JavaScriptCore/heap/Heap.cpp

    r246565 r246881  
    9797#endif
    9898
    99 #if USE(GLIB)
     99#ifdef JSC_GLIB_API_ENABLED
    100100#include "JSCGLibWrapperObject.h"
    101101#endif
     
    478478void Heap::releaseDelayedReleasedObjects()
    479479{
    480 #if USE(FOUNDATION) || USE(GLIB)
     480#if USE(FOUNDATION) || defined(JSC_GLIB_API_ENABLED)
    481481    // We need to guard against the case that releasing an object can create more objects due to the
    482482    // release calling into JS. When those JS call(s) exit and all locks are being dropped we end up
  • trunk/Source/JavaScriptCore/heap/Heap.h

    r245808 r246881  
    8787struct CurrentThreadState;
    8888
    89 #if USE(GLIB)
     89#ifdef JSC_GLIB_API_ENABLED
    9090class JSCGLibWrapperObject;
    9191#endif
     
    280280    template<typename T> void releaseSoon(RetainPtr<T>&&);
    281281#endif
    282 #if USE(GLIB)
     282#ifdef JSC_GLIB_API_ENABLED
    283283    void releaseSoon(std::unique_ptr<JSCGLibWrapperObject>&&);
    284284#endif
     
    665665    unsigned m_delayedReleaseRecursionCount { 0 };
    666666#endif
    667 #if USE(GLIB)
     667#ifdef JSC_GLIB_API_ENABLED
    668668    Vector<std::unique_ptr<JSCGLibWrapperObject>> m_delayedReleaseObjects;
    669669    unsigned m_delayedReleaseRecursionCount { 0 };
  • trunk/Source/JavaScriptCore/heap/HeapInlines.h

    r245808 r246881  
    165165#endif
    166166
    167 #if USE(GLIB)
     167#ifdef JSC_GLIB_API_ENABLED
    168168inline void Heap::releaseSoon(std::unique_ptr<JSCGLibWrapperObject>&& object)
    169169{
Note: See TracChangeset for help on using the changeset viewer.