Re: [EMACS] python-mode patch, 1.08a -> 1.08ax

Guido.van.Rossum@cwi.nl
Wed, 20 Apr 1994 11:40:52 +0200

> Sometimes the suggested indentation under both schemes is irritating (no
> more so than under the old scheme, though!); send examples of what you
> don't like along with a precise statement of what you _would_ have liked
> instead, & I'll try to infer better rules. Examples that require
> telepathy or prognostication are especially encouraged <snort>.

Tim, I like the new scheme much better than the old one!

Yet, I have collected a few cases where I'd like to see something
else...

1) Initializing a long table, as follows:

weekday_translations = {
'Monday': 'Maandag',
'Tuesday': 'Dinsdag',
...
}

Having the contents of the table indent all the way up to the left '['
is clumsy. I am happy to manually dedent the first continuation line
to where I want it, but your code currently jumps back to its
"preferred" indentation for each next line.

2) The rule for stuff indented with a backslash now seems to indent
until after the first space. That's fine for cases like

if a_very_long_test(_pah_) and \
another_very_complicated_test(_snort_):
pass

but has funny effects for assignments like

matrix[1, 1] = a_boring_long_vector(_giggle_) + \
another_very_long_expression(_wink_)

where I would have preferred this:

matrix[1, 1] = a_boring_long_vector(_giggle_) + \
another_very_long_expression(_wink_)

or
a, b, c, d, e = \
the_result_of_a_function_returning_a_quintuple()

where I don't know what I would've wanted, honestly.

Admitting-I-haven't-read-the-new-wonderful-documentation-yet,

--Guido van Rossum, CWI, Amsterdam <Guido.van.Rossum@cwi.nl>
URL: <http://www.cwi.nl/cwi/people/Guido.van.Rossum.html>