On Fri, Jan 17, 2014 at 6:56 PM, Niklas Voss <[email protected]> wrote:
> [...] > * How can I successfully register an extension? > Your code fragment looks OK *if* the strings you pass to the Extension constructor are still alive at the point where the Context is created, there is even a warning comment about this in v8.h. RegisterExtension just copies the pointers, not the string contents. Later when you create a Context those pointers are dereferenced and those strings should better be alive. Yes, this is a terrible API, but that's how it is... :-P > * If a context is composed out of extensions only is it possible to > execute the context without a script? > I don't know what "executing a context" should mean. > * Is it possible to share and object template between multiple threads and > isotopes (avoid the reconstruction)? > What is an "isotope" in this context? If you mean "Isolate": You intentionally can't share things between Isolates, hence the name. OTOH you can use threading if you use v8::Locker and ensure that only one thread at a time executes code within a given v8 Isolate (in other words: v8 is not magically thread-safe). On the positive side: Multiple threads can happily execute different Isolates at the same time, and one thread can switch between various Isolates. -- -- 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/groups/opt_out.
