[Python-3000] Octal

Jim Jewett jimjjewett at gmail.com
Fri Mar 16 18:38:00 CET 2007


On 3/15/07, Patrick Maupin <pmaupin at gmail.com> wrote:
> I have not seen any real
> requests for any bases other than 2, 8, 10, or 16.

What is the real need for 8?

The only use I've seen on the list is unix file permissions.  Even if
that weren't obscure enough to stick in a module, I would still rather
see

    chmod g+x

than something that requires a man page for translation.

FWIW, I have actually used octal literals (in C) for an old wire
protocol.  It did conform with the surrounding code, but ... that
didn't make it readable, either to me or to the usual maintainers.
This oddball code wasn't the only thing they had to maintain, and they
were young enough (mostly born in the late 1960s) to sometimes forget
the "leading 0 <==> octal" rule.

-jJ


More information about the Python-3000 mailing list