W3C home > Mailing lists > Public > public-webont-comments@w3.org > July 2008

RE: ISSUE-126 (Revisit Datatypes): A new proposal for the real <-> float <-> double conundrum

From: Dave Peterson <davep@iit.edu>
Date: Tue, 8 Jul 2008 22:02:14 -0400
Message-Id: <a0624081bc499caa679f8@[192.168.1.100]>
To: Michael Kay <mike@saxonica.com>, paul@sparrow-hawk.org, "'Alan Ruttenberg'" <alanruttenberg@gmail.com>
Cc: "'Rob Shearer'" <rob.shearer@comlab.ox.ac.uk>, public-webont-comments@w3.org, public-owl-wg@w3.org, www-xml-schema-comments@w3.org

At 7:54 PM +0100 2008-07-08, Michael Kay wrote:

>(b) it claims the existence of a "principle that if a string
>maps to a given value in a particular type then it should map to the same
>value
>in all supertypes". I don't see that principle as being in any way
>fundamental, and I certainly don't see it as "fundamental to subtyping in
>programming languages". It's also violated within XML Schema itself - " xx "
>as an instance of xs:token maps to a different value from " xx " as an
>xs:string.

Not so.  ' xx ' is not in the lexical space of token.  The literal that
is considered for lexical space membership is the one that is obtained
by whitespace processing.

Whether this is good or bad is a matter of opinion, I suppose.  But that's
the way whitespace works.  (Took me a few years to really internalize
this, myself.)

Whether the primciples themselves are good is a matter of opinion.
But I hope we don't change things from one version of the spec to the
next without serious thought.  (E.g., there was serious thought given
to the decision to allow equality to differ from identity, to have
two zeros in float and double, and to retain timezone information in
the date/time datatypes.)
-- 
Dave Peterson
SGMLWorks!

davep@iit.edu
Received on Wednesday, 9 July 2008 02:59:11 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 7 December 2009 10:43:30 GMT