W3C home > Mailing lists > Public > public-qt-comments@w3.org > May 2004

RE: Casting/constructors should accept the empty sequence

From: Michael Rys <mrys@microsoft.com>
Date: Sat, 29 May 2004 18:29:45 -0700
Message-ID: <EB0A327048144442AFB15FCE18DC96C703083A4C@RED-MSG-31.redmond.corp.microsoft.com>
To: "Michael Kay" <mhk@mhk.me.uk>, "Ashok Malhotra" <ashokmalhotra@alum.mit.edu>, "Don Chamberlin" <chamberl@almaden.ibm.com>
Cc: <public-qt-comments@w3.org>

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

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 15:45:19 UTC