This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.
In the XQFO spec – or in the XQUF spec? – it should probably be mentioned what is going to happen if an updating function is supplied to a higher-order function. Examples: apply(function() { delete node <a/> }, []) for-each-pair( <a/>, 'a.xml', function($node, $uri) { fn:put($node, $uri) } ) Maybe XPTY0004 could be raised?
XQuery Update 3.0 states: A FunctionTest without an updating function assertion only matches simple functions as it does in unextended XQuery 3.0. The signature of higher-order functions defined in F+O does not include an updating function assertion, and therefore updating functions cannot be supplied as arguments to functions such as apply() and for-each-pair(). Since the spec states that an updating function "is not matched", I think this implies that XPTY0004 is raised.
The WG agreed with my response, and decided to close as WORKSFORME. Please re-open if you think we've got it wrong.