Here's what Jochen originally said:

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


https://groups.google.com/d/msg/v8-users/Rshbi2HKYCM/LgwY-iJeAQAJ

He later clarified "the function template won't ever get gc'd after you've 
instantiated it once."

What I really want to know is why this is the case, and what purpose it 
serves.

~Theodore

On Sunday, November 20, 2016 at 2:09:38 PM UTC-8, [email protected] wrote:
>
> Jochen Eisinger said that "v8 has an per-isolate cache of function 
> templates". I have a few questions about this cache:
>
> If I create multiple FunctionTemplates with different callback data but 
> the same callback function and everything else, does it only create one 
> function template and use the cache for the rest?
> If not, why does the cache exist?
>
> ~Theodore
>

-- 
-- 
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.

Reply via email to