File tree Expand file tree Collapse file tree 2 files changed +11
-1
lines changed Expand file tree Collapse file tree 2 files changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -140,7 +140,8 @@ def lru_cache(maxsize=128): # noqa as it's a fake implementation.
140
140
WHITESPACE_AFTER_COMMA_REGEX = re .compile (r'[,;:]\s*(?: |\t)' )
141
141
COMPARE_SINGLETON_REGEX = re .compile (r'(\bNone|\bFalse|\bTrue)?\s*([=!]=)'
142
142
r'\s*(?(1)|(None|False|True))\b' )
143
- COMPARE_NEGATIVE_REGEX = re .compile (r'\b(not)\s+[^][)(}{ ]+\s+(in|is)\s' )
143
+ COMPARE_NEGATIVE_REGEX = re .compile (r'\b(?<!is\s)(not)\s+[^][)(}{ ]+\s+'
144
+ r'(in|is)\s' )
144
145
COMPARE_TYPE_REGEX = re .compile (r'(?:[=!]=|is(?:\s+not)?)\s+type(?:s.\w+Type'
145
146
r'|\s*\(\s*([^)]*[^ )])\s*\))' )
146
147
KEYWORD_REGEX = re .compile (r'(\s*)\b(?:%s)\b(\s*)' % r'|' .join (KEYWORDS ))
Original file line number Diff line number Diff line change 64
64
#: E714
65
65
if not X .B is Y :
66
66
pass
67
+ #: E714
68
+ if not X is Y is not Z :
69
+ pass
70
+ #: E714
71
+ if not X is not Y :
72
+ pass
67
73
68
74
#
69
75
#: Okay
79
85
if x is not y :
80
86
pass
81
87
88
+ if X is not Y is not Z :
89
+ pass
90
+
82
91
if TrueElement .get_element (True ) == TrueElement .get_element (False ):
83
92
pass
84
93
You can’t perform that action at this time.
0 commit comments