[Python-Dev] Octal literals
jcarlson at uci.edu
Wed Feb 1 18:47:34 CET 2006
bokr at oz.net (Bengt Richter) wrote:
> On Wed, 01 Feb 2006 12:33:36 +0000, "Gustavo J. A. M. Carneiro" <gjc at inescporto.pt> wrote:
> > Hmm.. I'm beginning to think 13r16 or 16r13 look too cryptic to the
> >casual observer; perhaps a suffix letter is more readable, since we
> >don't need arbitrary radix support anyway.
[snip discussion over radix and compliments]
I hope I'm not the only one who thinks that "simple is better than
complex", at least when it comes to numeric constants. Certainly it
would be _convenient_ to express constants in a radix other than decimal,
hexidecimal, or octal, but to me, it all looks like noise.
Peronally, I was on board for the removal of octal literals, if only
because I find _seeing_ a leading zero without something else (like the
'x' for hexidecimal) to be difficult, and because I've found little use
for them in my work (decimals and hex are usually all I need).
Should it change for me? Of course not, but I think that adding
different ways to spell integer values will tend to confuse new and
seasoned python users. Some will like the flexibility that adding new
options offers, but I believe such a change will be a net loss for the
understandability of those pieces of code which use it.
More information about the Python-Dev