v8 has an per-isolate cache of function templates. As the string is referenced by the function template, it will never go out of scope.
I'd recommend to create a weak handle to the function you create via GetFunction() instead On Mon, Oct 3, 2016 at 12:27 PM Pavel Medvedev <[email protected]> wrote: > Hi Theodore, > > In this program, weak_callback never gets called. Anyone know why? > > > There is no isolate->Enter() after Isolate::New(params), and no > context->Enter() after Context::New(isolate). May it be a reason? > > > -- > -- > v8-users mailing list > [email protected] > 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 [email protected]. > For more options, visit https://groups.google.com/d/optout. > -- -- v8-users mailing list [email protected] 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 [email protected]. For more options, visit https://groups.google.com/d/optout.
