Re: change dom3 core to not throw WRONG_DOCUMENT_ERR

On 8/31/10 6:58 PM, Joćo Eiras wrote:
> The spec has always enforced WRONG_DOCUMENT_ERR, but Mozilla has always
> had the bug.

Note that we did try to fix the bug at one point.  It turned out that 
the only way to do it (even if we were willing to accept breakage of 
gecko-specific code in web pages, which we considered) was to allow 
moving nodes from XHR responseXML into the DOM without explicit adopt 
calls, because IE allowed it, iirc.

At that point, it seemed pretty weird to require adoption for some 
cross-document movement but not others, so the patch was backed out.

> Although I would personally agree that firing the exception is better
> from a strict programming point of view, web compat will probably
> require the implicitly adoptNode forever.

I believe this is true, yes.

-Boris

Received on Tuesday, 31 August 2010 23:54:39 UTC