Python-list Digest, Vol 18, Issue 208
"Martin v. Löwis"
martin at v.loewis.de
Wed Mar 16 01:06:55 CET 2005
Jeff Shannon wrote:
> I'd be in favor of that, unless someone can come up with a compelling
> current use-case for octal literals.
Existing code. It may use octal numbers, and it would break if they
suddenly changed to decimal. Not only that - breakage would be *silent*,
i.e. the computations would just use incorrect numbers. You could make
breakage explicit, by disallowing leading zeroes in integer literals -
but still, programs would break.
As for functional use-cases: os.chmod is the typical example:
gives rw-rw---- access to /tmp/bla. Unix permission line up nicely
with octal numbers.
More information about the Python-list