[jsc-dev] JSValueRef lifecycle
tevaum at gmail.com
tevaum at gmail.com
Mon Nov 28 15:33:28 PST 2016
Thanks, Geoff.
One more thing, if I use JSRetainPtr for the context, what happens to the
values when the context is destroyed? Does the value keep a reference of
the context and the context won't be destroyed until all values are garbage
collected? Or will the context be destroyed and the value will be in an
invalid state, referencing an invalid context?
On 18:24, Mon, Nov 28, 2016 Geoffrey Garen <ggaren at apple.com> wrote:
So I'm asking you guys: what happens with values? Are they just garbage
collected? Do they keep a reference of the context or the other way around?
Is there a place where I can learn more about JSC besides the code?
Values on the stack are garbage collected. If you store a reference to a
value in the heap, you need to call JSValueProtect/JSValueUnprotect.
Geoff
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/jsc-dev/attachments/20161128/1d79c118/attachment.html>
More information about the jsc-dev
mailing list