On Jun 02, 2011, at 03:07 PM, R. David Murray wrote: >Personally, I use "enough" indentation. Sometimes that is a single >indentation level, but sometimes it is more. Two spaces is definitely >right out, though :) > >The place where a single indentation level is *not* enough is when the >line being indented is the statement starting a suite: > > for x in long_function_name( > var_one, var_two, var_three): > print x > > vs > > for x in long_function_name( > var_one, var_two, var_three): > print x > >That's a case where I'd be likely to use even more than two indentation >levels. Usually, though, I try to refactor the statement so it fits >on one line.
That's a recommendation I can definitely get on board with! I do exactly the same thing, although sometimes I use a comment between the compound statement and the indented stanza. -Barry
signature.asc
Description: PGP signature
_______________________________________________ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com