Tim Peters <tim.pet...@gmail.com> added the comment: +inf == +inf, and -inf == -inf, are required by the 754 standard. However, +inf - +inf, and -inf - -inf, are required (by the same standard) to signal invalid operation and, if that signal is masked (as it is in Python), to return a NaN. Then NaN == x is false for any value of x (including a NaN).
OTOH, +inf != -inf, +inf - -inf == +inf, and -inf - +inf == -inf. Current versions of Python implement all of that. ---------- nosy: +tim_one _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue6675> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com