[Issue 13499] (float|double|real).compare functions improperly compare nan

d-bugmail at puremagic.com d-bugmail at puremagic.com
Tue Jan 30 12:39:04 UTC 2018


https://issues.dlang.org/show_bug.cgi?id=13499

--- Comment #3 from Steven Schveighoffer <schveiguy at yahoo.com> ---
I don't know what to propose. You are right that there is no valid return.

I don't even remember what prompted me to create this bug (wish I had wrote
more context here), as it was so long ago. If I had to guess, it was because
AA's at the time may have still used a tree to store bucket collisions, and
compare was messing up if you used a float as a key type.

But these days, that isn't the case, and the builtin sort property is gone, so
very little code actually uses TypeInfo.compare.

I would guess that perhaps, while this is still a bug, it isn't as significant
as it once was.

--


More information about the Digitalmars-d-bugs mailing list