This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.
It would be nice if XQuery 3.0 provided a way to perform a shallow copy of the context node while preserving its namespace context (like <xsl:copy> in XSLT). In the current draft, the only way to do that would be to write the following: $el ! element {node-name(.)} { for $prefix in in-scope-prefixes(.) let $uri := namespace-uri-for-prefix($prefix, .) return namespace {$prefix} {$uri}, "new-value" } whereas in XSLT, you'd just write: <xsl:copy>new-value</xsl:copy> It would be nice if XQuery 3.0 provided a simpler way to do this, e.g., through a shallow copy constructor, using syntax that looks something like this: copy {...} So the above example could be written like this instead: $el ! copy { "new-value" }
Assigning to future requirements per Working Group decision (https://lists.w3.org/Archives/Member/w3c-xsl-query/2012Oct/0087.html).