You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
… output
When you construct a DOM tree containing subtrees which are constructed
top-down, this won't remove the redundant namespaces. That's because the
following conditions hold:
1) The namespace are reused from the doc->oldNs list.
2) Therefore during reconciliation no nsDef field is set, so no redundant
namespaces are removed by our reconciliation code.
Furthermore, it would only be fixed up automatically if the tree wasn't
added in bottom-up way, or if it had been constructed bottom-up from the
start.
Fix it by setting a flag to remove redundant namespaces in the libxml2
reconciliation call.
Since removing redundant namespaces may have a performance cost, we only do
this after performing a simple check.
Description
The following code:
Resulted in this output:
But I expected this output instead:
Only the nightly build from the master branch seems to be affected.
With the stable releases this bug does not occur, see https://3v4l.org/hAXOS
Related: #11428 (comment)
PHP Version
8.3.0-dev fe6263e
ext-dom: 20031129
lib-libxml: 2.9.4
Operating System
No response
The text was updated successfully, but these errors were encountered: