Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions pep-0008.txt
Original file line number Diff line number Diff line change
Expand Up @@ -310,6 +310,18 @@ Note, some editors and web-based code viewers may not recognize
control-L as a form feed and will show another glyph in its place.


Empty blocks
------------

Use ``pass`` to denote a block is intentionally empty. In empty

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

...block which is intentionally left empty.

class or function bodies, prefer a meaningful docstring instead of
``pass``.

Do not use ``...`` or ``None`` for this purpose. The former suggests
"details supressed" instead of "there is nothing there". The latter

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo: suppressed

looks like an unfinished thought.


Source File Encoding
--------------------

Expand Down Expand Up @@ -642,6 +654,7 @@ Other Recommendations

if foo == 'blah': one(); two(); three()


When to Use Trailing Commas
===========================

Expand Down