Skip to content

Commit 19b55a9

Browse files
committed
remove python 2.x handling of <> and -> operators
1 parent 8c79b21 commit 19b55a9

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

pycodestyle.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@
107107
ARITHMETIC_OP = frozenset(['**', '*', '/', '//', '+', '-', '@'])
108108
WS_OPTIONAL_OPERATORS = ARITHMETIC_OP.union(['^', '&', '|', '<<', '>>', '%'])
109109
WS_NEEDED_OPERATORS = frozenset([
110-
'**=', '*=', '/=', '//=', '+=', '-=', '!=', '<>', '<', '>',
110+
'**=', '*=', '/=', '//=', '+=', '-=', '!=', '<', '>',
111111
'%=', '^=', '&=', '|=', '==', '<=', '>=', '<<=', '>>=', '=',
112112
'and', 'in', 'is', 'or', '->', ':='])
113113
WHITESPACE = frozenset(' \t\xa0')
@@ -905,10 +905,6 @@ def missing_whitespace_around_operator(logical_line, tokens):
905905
yield (need_space[0],
906906
"E225 missing whitespace around operator")
907907
need_space = False
908-
elif text == '>' and prev_text in ('<', '-'):
909-
# Tolerate the "<>" operator, even if running Python 3
910-
# Deal with Python 3's annotated return value "->"
911-
pass
912908
elif (
913909
# def f(a, /, b):
914910
# ^

0 commit comments

Comments
 (0)