W3C home > Mailing lists > Public > public-qt-comments@w3.org > July 2009

[Bug 6998] Test orderBy35 / values larger than 1.0E6

From: <bugzilla@wiggum.w3.org>
Date: Thu, 09 Jul 2009 00:09:05 +0000
To: public-qt-comments@w3.org
Message-Id: <E1MOhCD-0004lg-IM@wiggum.w3.org>

--- Comment #10 from Bogdan Butnaru <bogdanb+w3c+bugzilla@gmail.com>  2009-07-09 00:09:05 ---
(In reply to comment #8)
> So as far as testing is concerned, any test whose result is floating point (or
> that contains the serialization of a value that includes floating point) has an
> infinite number of correct answers. This is clearly unsatisfactory, but it's
> hard to find a good way forward. Pragmatically, it can be useful when regular
> comparison of results fails, to try again parsing both results as float and
> outputting a comment if this succeeds, to aid manual inspection.

I haven't thought this through very thoroughly, but I believe that for most
float numbers there should be a (relatively simple) way to determine that a
string value is a correct representation of that float number, using only
string operations:

AFAIK, for most if not all float numbers, and with the specific restrictions in
the spec regarding the position of the decimal separator, all valid mantissas
that can represent it form a set of strings that is infinite but is bounded
lexicographically at both ends by a well-defined pair of strings. I _think_
that the exponent can't vary, so in principle it should be possible to check
the string values using only string operations.

(This excludes values in the 1E-6 – 1E+6 range, where I believe the spec
allows a single representation, and of course NaN and infinities.)

I intend to investigate this further and propose concrete changes. This will
probably mean using the exact value for the restricted millionth–million
range, writing a tool that generates the extremes for any value outside that
range, and changes to affected tests. I'm in the middle of something else right
now, so that is not likely to come before the end of summer. However, if there
is a specific reason to hurry (e.g., an imminent new release of the test suite)
and nobody else offers, let me know, I'll probably be able to take a couple of
days to work it through.

Configure bugmail: http://www.w3.org/Bugs/Public/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
Received on Thursday, 9 July 2009 00:09:17 UTC

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