a with directly after an if costs me 8 spaces instead of 4.\
Frankly, I think many (most) uses of with are a waste of an indentation level. For example, if all I'm doing is opening a file -- that isn't "logically" a separate block.
In fact, I find myself reading entire files into memory and then processing them, so as to avoid having to extra-indent all the processing code.
The point being that the problem is not with "if" not having a feature, but with with (heh, heh) itself in many contexts.
All that being said, it's not that big a deal, and I personally don't try to limit to 80 chars per line anyway -- preferring 90 or 95 -- I haven't used a VT100 in decades ....
It's the price we pay for nifty feature.
-Chris B
PS -- your linter will yell at you, but you COULD simply use 2 spaces for a if:with combo.
-- Christopher Barker, PhD (Chris)
Python Language Consulting
- Teaching
- Scientific Software Development
- Desktop GUI and Web Development
- wxPython, numpy, scipy, Cython