Updates:
        Status: WorkingAsIntended

Comment #2 on issue 1223 by [email protected]: JSON stringify on host objects ends up with a recursion error
http://code.google.com/p/v8/issues/detail?id=1223

Obviously, the structure *is* cyclic:
  var div = document.createElement("div");
alert(div.ownerDocument == div.ownerDocument.body.ownerDocument); // true. The question is whether something should prevent JSON stringify from following any of these properties. It seems there isn't anything in WebKit DOM objects that makes them not stringify. Firefox DOM objects seem to be "special". The actual properties sit on an inherited [xpconnect wrapped native prototype], which seems to break JSON.stringify. I can't see what IE is doing right now, but it's probably also a case of not stringifying hosy objects.

There is nothing in the ECMAScript specification that specify how host objects should work, so there is nothing right or wrong.
I'm satisfied that we follow Safari in how we deal with WebKit DOM objects.


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

Reply via email to