[Webkit-unassigned] [Bug 228892] New: [JSC] Custom getter / setter functions can be collected

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Aug 6 22:15:57 PDT 2021


https://bugs.webkit.org/show_bug.cgi?id=228892

            Bug ID: 228892
           Summary: [JSC] Custom getter / setter functions can be
                    collected
           Product: WebKit
           Version: WebKit Nightly Build
          Hardware: Unspecified
                OS: Unspecified
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: JavaScriptCore
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: ysuzuki at apple.com

It is weakly held. This means that they can be collected if nobody references it.
So,

{
    var getter = Object.getOwnPropertyDescriptor(RegExp, "rightContext").get;
    getter.mark = true;
}

// Make GC happens.

{
    var getter = Object.getOwnPropertyDescriptor(RegExp, "rightContext").get;
    print(getter.mark); // => undefined
}

We need to keep these accessors strongly in the holder.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20210807/390293fb/attachment-0001.htm>


More information about the webkit-unassigned mailing list