Additional PEP 8 tweaks
- be explicit that project style guides take precedence - make a line splitting example consistent with other guidelines - clarify wording of the def-vs-lambda guideline
This commit is contained in:
parent
69ab45adcc
commit
ad0edb7348
|
@ -28,6 +28,10 @@ This style guide evolves over time as additional conventions are
|
||||||
identified and past conventions are rendered obsolete by changes in
|
identified and past conventions are rendered obsolete by changes in
|
||||||
the language itself.
|
the language itself.
|
||||||
|
|
||||||
|
Many projects incorporate this guide by reference into their own style
|
||||||
|
guides. In the event of any conflicts, the project-specific style guide
|
||||||
|
takes precedence.
|
||||||
|
|
||||||
|
|
||||||
A Foolish Consistency is the Hobgoblin of Little Minds
|
A Foolish Consistency is the Hobgoblin of Little Minds
|
||||||
======================================================
|
======================================================
|
||||||
|
@ -882,8 +886,8 @@ Programming Recommendations
|
||||||
operator. However, it is best to implement all six operations so
|
operator. However, it is best to implement all six operations so
|
||||||
that confusion doesn't arise in other contexts.
|
that confusion doesn't arise in other contexts.
|
||||||
|
|
||||||
- Always use a def statement instead of assigning a lambda expression
|
- Always use a def statement instead of an assignment statement that binds
|
||||||
to a name.
|
a lambda expression directly to a name.
|
||||||
|
|
||||||
Yes::
|
Yes::
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue