Skip to content

Commit

Permalink
Handle
Browse files Browse the repository at this point in the history
  • Loading branch information
Susannah Klaneček committed May 1, 2020
1 parent 5230110 commit 39895aa
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pycodestyle.py
Original file line number Diff line number Diff line change
Expand Up @@ -140,8 +140,8 @@ def lru_cache(maxsize=128): # noqa as it's a fake implementation.
WHITESPACE_AFTER_COMMA_REGEX = re.compile(r'[,;:]\s*(?: |\t)')
COMPARE_SINGLETON_REGEX = re.compile(r'(\bNone|\bFalse|\bTrue)?\s*([=!]=)'
r'\s*(?(1)|(None|False|True))\b')
COMPARE_NEGATIVE_REGEX = re.compile(r'\b(not)\s+[^][)(}{ ]+\s+(in|is)'
r'\s+(?!not\s)')
COMPARE_NEGATIVE_REGEX = re.compile(r'\b(?<!is\s)(not)\s+[^][)(}{ ]+\s+'
r'(in|is)\s')
COMPARE_TYPE_REGEX = re.compile(r'(?:[=!]=|is(?:\s+not)?)\s+type(?:s.\w+Type'
r'|\s*\(\s*([^)]*[^ )])\s*\))')
KEYWORD_REGEX = re.compile(r'(\s*)\b(?:%s)\b(\s*)' % r'|'.join(KEYWORDS))
Expand Down
3 changes: 3 additions & 0 deletions testsuite/E71.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,9 @@
#: E714
if not X is Y is not Z:
pass
#: E714
if not X is not Y:
pass

#
#: Okay
Expand Down

0 comments on commit 39895aa

Please sign in to comment.