Chris Rebert c...@rebertia.com writes:
Or, if possible, refactor the conditional into a function (call) so
it's no longer multiline in the first place.
No! This /increases/ cognitive load for readers, because they have to
deal with the indirection through the name. If you actually use the
On Thu, Nov 4, 2010 at 11:09 AM, Mark Wooding m...@distorted.org.uk wrote:
Chris Rebert c...@rebertia.com writes:
Or, if possible, refactor the conditional into a function (call) so
it's no longer multiline in the first place.
No! This /increases/ cognitive load for readers, because they
Hi,
This is a mini-proposal I piggy-tailed in the other topic:
Allow the conditions in the if-, elif-, while-, for-, and
with-clauses to span multiple lines without using a backlalsh
at the end of a line,
just like when you specify literal lists, tuples, dicts, etc.
across multiple lines
Yingjie Lan lany...@yahoo.com writes:
Allow the conditions in the if-, elif-, while-, for-, and with-clauses
to span multiple lines without using a backlalsh at the end of a line,
You can already do this with any expression: use parentheses.
Yingjie Lan lany...@yahoo.com writes:
I would
In message 874oc1ldo6@benfinney.id.au, Ben Finney wrote:
Yingjie Lan lany...@yahoo.com writes:
Allow the conditions in the if-, elif-, while-, for-, and with-clauses
to span multiple lines without using a backlalsh at the end of a line,
You can already do this with any expression: use
On Sun, 31 Oct 2010 23:02:21 -0700, Yingjie Lan wrote:
Hi,
This is a mini-proposal I piggy-tailed in the other topic:
Allow the conditions in the if-, elif-, while-, for-, and with-clauses
to span multiple lines
[...]
also, if we don't allow it, people just have to use
parenthesis
On Mon, Nov 1, 2010 at 12:51 AM, Steven D'Aprano
steve-remove-t...@cybersource.com.au wrote:
On Sun, 31 Oct 2010 23:02:21 -0700, Yingjie Lan wrote:
Hi,
This is a mini-proposal I piggy-tailed in the other topic:
Allow the conditions in the if-, elif-, while-, for-, and with-clauses
to span
Chris Rebert c...@rebertia.com wrote:
Or, if possible, refactor the conditional into a function (call) so
it's no longer multiline in the first place.
Or even simpler, assign the condition result to a variable:
a_b_positive = a 0 and b 0
if a_b_positive:
...
--