Comparisons and sorting of a numeric class....

Chris Angelico rosuav at gmail.com
Fri Jan 23 06:58:03 EST 2015


On Fri, Jan 23, 2015 at 10:46 PM, Andrew Robinson
<andrew3 at r3dsolutions.com> wrote:
> 4.  and he has made bool into the default return type for base type
> comparison operators; which means that general programmers expect a bool for
> base types and may check for it, even if Python's built in functions do not.

I don't get this. They're specifically documented as NOT being
required to return a bool, so if any code is type-checking the return
values, that code is buggy.

ChrisA



More information about the Python-list mailing list