W3C home > Mailing lists > Public > public-qt-comments@w3.org > September 2015

[Bug 29044] array:sort does not define a total order when keys contain NaN

From: <bugzilla@jessica.w3.org>
Date: Wed, 02 Sep 2015 16:55:27 +0000
To: public-qt-comments@w3.org
Message-ID: <bug-29044-523-NsxwuvdTT5@http.www.w3.org/Bugs/Public/>

Michael Kay <mike@saxonica.com> changed:

           What    |Removed                     |Added
             Status|NEW                         |ASSIGNED

--- Comment #2 from Michael Kay <mike@saxonica.com> ---
I was actioned to propose a resolution.

Note that XSLT says:

NaN values, for sorting purposes, are considered to be equal to each other, and
less than any other numeric value.

XQuery is rather more convoluted; it doesn't mention NaN by name, but it has
the same effect in that if V is NaN and W is NaN then neither V nor W is
greater than the other and therefore they behave in the same way as a pair of
values that are equal.

I propose to use the fix suggested by Josh, of using deep-equal() rather than
eq in the definition of the deep-less-than function.

The changes have been applied, but the bug is left open for WG approval of the

You are receiving this mail because:
You are the QA Contact for the bug.
Received on Wednesday, 2 September 2015 16:55:32 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 16:57:55 UTC