RE: [XQuery]&[F&O] fn:error: function parameters

> The WGs discussed your request on the telcon today.  Since, 
> as a rule, we do not overload function
> signatures we cannot have one signature for fn:error that 
> takes a single QName and another that takes
> a single string.  So, we decided to change the third and 
> fourth signatures of fn:error and make the
> QName optional.  In these two cases, if you pass the empty 
> sequence as the first (QName) argument
> the function behaves as if you had passed the QName 
> corresponding to err:FOER0000 -- Unidentified Error.

A mischievous note: it is therefore an error to call the function with a
single string argument, e.g.

error("No input")

But since it's implementation-defined what the error message for this error
is, an implementation that outputs "Error: No input" would be entirely
conformant...

Michael Kay

Received on Tuesday, 28 September 2004 22:21:21 UTC