fix #68882, cleanup the XInclude copying of node, merge back IDs in the

* tree.c valid.c xinclude.c: fix #68882, cleanup the XInclude
  copying of node, merge back IDs in the target document.
* result/XInclude/docids.xml test/XInclude/docs/docids.xml
  test/XInclude/ents/ids.xml: test case
* result/VC/ElementValid4: output changed due to a typo fix
Daniel
diff --git a/result/XInclude/docids.xml b/result/XInclude/docids.xml
new file mode 100644
index 0000000..a383e7f
--- /dev/null
+++ b/result/XInclude/docids.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0"?>
+<!DOCTYPE book [
+<!ELEMENT book (doc)*>
+<!ELEMENT doc (isid)*>
+<!ELEMENT isid EMPTY>
+<!ATTLIST isid myid ID #IMPLIED>
+]>
+<book>
+<doc>
+<isid myid="mine"/>
+<isid myid="dup"/>
+</doc>
+<!-- including another XML document with IDs -->
+<doc>
+<isid myid="dup"/>
+<isid myid="foo"/>
+<isid myid="bar"/>
+</doc>
+</book>