News for hackers. Stuff that matters.
Re:How to compare floats in Python by eru on Thursday March 31, 2022 @01:49AM (#30864209)
If you use your own dataclasses (from dataclassy) instead of tuples, you can override this behaviour.

Making NaNs compare unequal to themselves was a hack that dates back from the time modern floats were first introduced.

There are no comments on this comment yet.