Default indentation of 4 columns
Gareth McCaughan
Gareth.McCaughan at pobox.com
Sun Oct 24 15:43:12 EDT 1999
François Pinard wrote:
> The only thing that really rebukes me is the interdiction to use capitals in
> comments to mark non-terminals (or variables), as it does not get accompanied
> by a better suggestion, or at least, none yielding as much clarity.
You mean saying things like
# Return the sum of AARDVARK and ARMADILLO.
def f(aardvark, armadillo):
return aardvark+armadillo
? (Incidentally, this example is another one that shows an
annoying "accidental alignment" as a result of the four-character
rule. That's one reason why I -- showing my depravity, no doubt --
prefer two characters.)
I use a convention derived from Knuth's literate programming
systems, and write
# Return the sum of |aardvark| and |armadillo|.
--
Gareth McCaughan Gareth.McCaughan at pobox.com
sig under construction
More information about the Python-list
mailing list