Skip to content
  • mhahnenberg@apple.com's avatar
    Objective-C API: Clean up JSValue · a9e9f9d1
    mhahnenberg@apple.com authored
    https://bugs.webkit.org/show_bug.cgi?id=107156
    
    Reviewed by Oliver Hunt.
    
    JSContext m_protectCounts, protect, unprotect are all now unnecessary overhead, and should all be removed.  
    These exist to handle the context going away before the value does; the context needs to be able to unprotect 
    values early.  Since the value is now keeping the context alive there is no longer any danger of this happening; 
    instead we should just protect/unprotect the value in JSValue's init/dealloc methods.
    
    * API/JSContext.mm:
    (-[JSContext dealloc]):
    * API/JSContextInternal.h:
    * API/JSValue.mm:
    (-[JSValue initWithValue:inContext:]):
    (-[JSValue dealloc]):
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@140031 268f45cc-cd09-0410-ab3c-d52691b4dbfc
    a9e9f9d1