On Sep 23, 2013, at 09:57 PM, Andreas Röhler wrote: >The OP wanted the Editor intends the second "print" to column 0. IMO it's >possibly establishing an edit rule saying: if an empty line follows a block, >consider this block closed.
As Diez mentioned, an option defaulting to off would be interesting to play with. I generally discourage using vertical whitespace inside methods, and mostly use it for structural separation, so I think this might be reasonable. It could only apply to actual blank lines, i.e. comments wouldn't trigger it. >def find(seq, target): > for i, value in enumerate(seq): > if value == tgt: > break > else: > return -1 > return i Actually, that else gets lined up under 'if' right now. >If an empty line after "break" is inserted: > >def find(seq, target): > for i, value in enumerate(seq): > if value == tgt: > break > > else: > return -1 > return i So I guess you're saying the blank line would add an extra dedent level? I hate to have people start to rely on this behavior to add non-structural vertical whitespace. If this feature is more helpful for top-level structures, then it might be useful, otherwise I'm skeptical. But as I say, it might be interesting to play with. -Barry
signature.asc
Description: PGP signature
_______________________________________________ Python-mode mailing list Python-mode@python.org https://mail.python.org/mailman/listinfo/python-mode