I have two questions.

#1
I'm developing a Node.js/Mongodb web app.

This means that objects used in the code will be created by at least two 
different code paths:

   1. Constructor functions
   2. Deserialization code in the mongo driver.

It is my understanding that hidden classes are not shared between different 
constructors, even if I construct structurally identical objects with the 
same properties and in the same order. This seems to imply that 
deserialized objects coming from mongodb will not share the same hidden 
class as structurally identical objects created by the constructors, hence 
functions that use these objects will not be well optimized into native 
code. Am I right?

#2
Is there any hidden class inheritance built into v8? That is, if I create 
object o={a:1, b:2} and later add o.z=3, will native code optimized for the 
hidden class before the property-add still work unmodified afterwards?

-- 
v8-users mailing list
[email protected]
http://groups.google.com/group/v8-users

Reply via email to