On Wed, Feb 28, 2018 at 6:19 AM, A.M. <cis74...@gmail.com> wrote:
>> The answer is "it depends."  If you're not going to call into V8 at
>> all it's _probably_ safe but most V8 APIs can kick off a GC run.  Call
>> `v8::Isolate::Dispose()` first to be safe.
>
> Is there a best-practices way to dispose of application objects stored in
> internal fields that didn't participate in any weak callbacks? Writing code
> to clear out internal fields and then deal with potentially-empty internal
> fields in all object callbacks makes the code unnecessarily complex, which
> is why I was looking for a more straightforward way. Any insights in this
> would be much appreciated. Thanks!

Not really, I'm afraid.  You can't really get around of doing double
bookkeeping.

It's a perennial source of bugs in Node.js but the upside is it keeps
me employed.

-- 
-- 
v8-users mailing list
v8-users@googlegroups.com
http://groups.google.com/group/v8-users
--- 
You received this message because you are subscribed to the Google Groups 
"v8-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to v8-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to