[Python-Dev] str with base
Andrew Bennetts
andrew-pythondev at puzzling.org
Wed Jan 18 07:22:27 CET 2006
Guido van Rossum wrote:
[...]
>
> I'd propose bin() to stay in line with the short abbreviated names.
>
[...]
>
> The binary type should have a 0b prefix.
It seems odd to me to add both a builtin *and* new syntax for something that's
occasionally handy, but only occasionally. If we're going to clutter a module
with this function, why not e.g. the math module instead of builtins? I thought
the consensus was that we had too many builtins already.
Similarly, the need for 0b101 syntax seems pretty low to me when you can
already do int("101", 2).
-Andrew.
More information about the Python-Dev
mailing list