[Python-Dev] Re: PEP 285: Adding a bool type

Terry Reedy tejarex at yahoo.com
Tue Apr 2 19:31:18 EST 2002


 Guido van Rossum wrote:

> I don't see the introduction of the bool type as painful at all.
> I find getting it accepted painful though. :-(

Part of the concern is 'why bother? or 'would't adding two builtin
names do as much good?'.

Another large part is the fear that you might someday be persuaded to
cripple the new type.  You made this fear seem reasonable by tossing
it out as a real possibility and by half-conceding the argument behind
such a move:

>         4) Should we strive to eliminate non-Boolean operations on
bools
>            in the future, through suitable warnings, so that e.g.
True+1
>            would eventually (e.g. in Python 3000 be illegal).

(Your follow-on sentence seems like a pretty weak endorsement of the
status quo:
>
Personally,
>            I think we shouldn't; 28+isleap(y) seems totally
reasonable to me.
)

My point about the name 'bool' is that this question and its
justification are at least partly an artifact of this proposed name.
If the sometimes non-boolean-acting values were called something else,
such as forb*, complaints that "Forbs do things 'non-Boolean!' " could
be met with "So what?" and "Yes, we know, that is why we did not call
them bools."

* FORced Binary choice.

Terry J. Reedy






More information about the Python-list mailing list