diff --git a/pep-0520.txt b/pep-0520.txt index 65a5b6e4b..dbd56ca86 100644 --- a/pep-0520.txt +++ b/pep-0520.txt @@ -85,8 +85,8 @@ default behavior:: ham = None eggs = 5 __definition_order__ = tuple(k for k in locals() - if (not k.startswith('__') or - not k.endswith('__'))) + if not (k.startswith('__') and + k.endswith('__'))) Note that [pep487_] proposes a similar solution, albeit as part of a broader proposal.