This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author pwuertz
Recipients docs@python, pwuertz
Date 2012-10-15.12:55:38
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1350305738.94.0.323061453439.issue16239@psf.upfronthosting.co.za>
In-reply-to
Content
I think the PEP8 examples for arithmetic expressions are a bit misleading. (http://www.python.org/dev/peps/pep-0008/#id20)

The text clearly says that it should add spaces around operators of low(est) priority, which means that I'm encouraged to visually group an expression of high priority. It doesn't say (anymore?) that there should always be spaces around all arithmetic operators.

This is however not reflected in the examples. In the examples
"x = x*2 - 1" is listed as a negative example, while being perfectly compliant with the guide. Shouldn't this be in the "Yes" or an "Optionally" example block?

I believe these examples may cause some people to interpret the style guide in a very rigid way, eventually leading to PEP8 formatting tools that flatten out nicely grouped expressions.
History
Date User Action Args
2012-10-15 12:55:38pwuertzsetrecipients: + pwuertz, docs@python
2012-10-15 12:55:38pwuertzsetmessageid: <1350305738.94.0.323061453439.issue16239@psf.upfronthosting.co.za>
2012-10-15 12:55:38pwuertzlinkissue16239 messages
2012-10-15 12:55:38pwuertzcreate