RE: Casting/constructors should accept the empty sequence

Correct. If you expect more than a single value (such as empty): use
xs:int?. 

Best regards
Michael

> -----Original Message-----
> From: public-qt-comments-request@w3.org [mailto:public-qt-comments-
> request@w3.org] On Behalf Of Michael Kay
> Sent: Saturday, May 29, 2004 2:18 PM
> To: 'Ashok Malhotra'; 'Don Chamberlin'; Michael Rys
> Cc: public-qt-comments@w3.org
> Subject: RE: Casting/constructors should accept the empty sequence
> 
> 
> >
> > Don, Michael:
> > We discussed your comments
> > http://lists.w3.org/Archives/Public/public-qt-comments/2004Mar
> /0211.html and http://lists.w3.org/Archives/Public/public-qt->
> comments/2004Mar/00891.html
> > in San Jose and agreed to make the following changes:
> >
> > 1. The constructor functions should accept the empty
> > sequence. If the empty sequence is passed to a constructor
> > function, the empty sequence is returned.
> >
> 
> I'm mildly curious about how I explain this to users of systems that
do
> static typing. Am I right in thinking that if you have a function
declared
> as:
> 
>    declare function f($x as xs:int) ...
> 
> then the call
> 
>    f(xs:int(3))
> 
> will now be a static type error?
> 
> Michael Kay
> 
> 

Received on Saturday, 29 May 2004 21:30:01 UTC