Happy Happy Joy Joy (was: On to Hydro)
Mark S. Miller
markm@caplet.com
Mon, 21 Aug 2000 22:59:57 -0700
At 04:02 PM 8/21/00 , Bill Frantz wrote:
>At 03:47 PM 8/21/00 -0700, Mark S. Miller wrote:
> >... What would you have
> >these containers do when asked to store and retrieve NaNs? Remember, the
> >containers don't know about numbers, only things with the properties needed
> >for these containers to hold them.
>
>Since NaN is the result of a computation gone bad, where it was too
>expensive to check every step, I think the correct answer is to throw an
>exception.
Ok, in order to have a definition of container behavior independent of
numbers, would you agree with my proposal that full-ordering containers
(like Hydro's RedBlackTrees) reject the addition of an element that isn't
<=> to itself, even if it is the initial element?
At 02:50 PM 8/21/00 , Tyler Close wrote:
>How on earth can you justify saying that a space of one element is not
>fully ordered?
"When I make a word do a lot of work like that," said Humpty Dumpty, "I
always pay it extra."
If I pay "fully ordered" extra, I can define a fully ordered list (indexed
from 0 to length-1) as one for which
for each pair of valid indexes i and j, i <= j implies list[i] <= list[j].
With this definition, [NaN] isn't fully ordered, since 0 <= 0 but !(NaN <=
NaN).
But again, I'm really happy with this issue either way. I just can't stop
myself ;).
Cheers,
--MarkM