[Bug 29141] [XSLT30] fn:snapshot and fn:copy-of talk about node (singular), where the signature allows nodes

https://www.w3.org/Bugs/Public/show_bug.cgi?id=29141

--- Comment #2 from Abel Braaksma <abel.braaksma@xs4all.nl> ---
(In reply to Michael Kay from comment #1)

> More complex scenarios are also possible, where the input sequence to copy()
> or snapshot() contains a node N and also one or more of its ancestor or
> descendant nodes. We could either allow the result to contain overlapping
> copies in this case, or we could insist that in the result of copy-of, each
> node is parentless and siblingless, and in the result of snapshot, each node
> is siblingless (which would imply multiple copies).

You mean as in:

copy-of(.. | .)

to return only the parent, as it already includes the current node? I think as
presently written, it returns a deep copy of the parent and a deep copy of the
current node, both being parentless. I think snapshot() should work the same
way.

Which is in line with applying templates with on-no-match="deep-copy".


(In reply to Michael Kay from comment #1)
> John Lumley also points out that we ought to be clear in the case where the
> same node is present more than once in the input sequence whether the output
> sequence will also contain the same node more than once, or whether each
> gets a different copy, or whether this is implementation-dependent. In
> keeping with the use of new-each-time="maybe", I think it should be
> implementation-dependent. 

I agree, it should be implementation-dependent.

-- 
You are receiving this mail because:
You are the QA Contact for the bug.

Received on Thursday, 24 September 2015 07:55:33 UTC