- From: <bugzilla@wiggum.w3.org>
- Date: Thu, 09 Aug 2007 16:34:39 +0000
- To: public-qt-comments@w3.org
- CC:
http://www.w3.org/Bugs/Public/show_bug.cgi?id=4939 Summary: [FO] Specify both "fn:f(a as t?) as r?" and "fn:f(a as t) as r" Product: XPath / XQuery / XSLT Version: Recommendation Platform: All URL: http://www.w3.org/TR/xquery-operators/ OS/Version: All Status: NEW Severity: enhancement Priority: P4 Component: Functions and Operators AssignedTo: mike@saxonica.com ReportedBy: bungeman@gmail.com QAContact: public-qt-comments@w3.org There are a large number of functions specified of the form like, for example, (http://www.w3.org/TR/xquery-operators/#func-years-from-duration) fn:years-from-duration($arg as xs:duration?) as xs:integer? which only return the empty sequence if the argument is the empty sequence. For static type checking purposes, it is often convenient to be able to specify that the type of an expression not contain the empty sequence, but this becomes difficult to reason about when so many functions may be returning empty sequence. It would be helpful if there were also function specifications of the form fn:years-from-duration($arg as xs:duration) as xs:integer with the additional static rule of choosing the most specific form (since this is obviously overloading the function name). There may be other ways of addressing this issue.
Received on Thursday, 9 August 2007 16:34:43 UTC