RE: XSLT 2.0 WD -- question about handling Nans

> In section 12.2 of the WD, the last paragraph says that NaNs 
> are less than any other value (including -INF).  This 
> conflicts with the XML Schema Data Model description 
> (sections 3.2.4 and 3.2.5), with which XSLT is supposed to 
> conform, that says that NaNs are greater than all other 
> values (including +INF).
> 
> So, we have two incompatible specs (3 if you count the IEEE 754 spec, 
> which says a third thing about NaNs).  Who gets to make them right?
> 

Yes, the discrepancy is unfortunate. The XSLT rule that NaN precedes other
values (note that this only applies to xsl:sort) was introduced as an
erratum to XSLT 1.0 (see E20 in
http://www.w3.org/1999/11/REC-xslt-19991116-errata/ ) and pre-dates the
publication of XML Schema, which adopted the opposite convention. It's not
obvious whether the problem is serious enough to be worth fixing, and if so,
how it should be fixed: as far as I can see it is untidy that the two specs
should adopt different conventions but it does not make anything actually
break.

Michael Kay
Software AG

Received on Monday, 26 August 2002 10:19:40 UTC