Skip to content

Commit fc2c2ba

Browse files
authored
Merge pull request #1254 from correctmost/cm/avoid-appends
Use list comprehensions to avoid append() calls
2 parents 3d5962b + bb41352 commit fc2c2ba

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

pycodestyle.py

+1-3
Original file line numberDiff line numberDiff line change
@@ -1910,9 +1910,7 @@ def readline(self):
19101910

19111911
def run_check(self, check, argument_names):
19121912
"""Run a check plugin."""
1913-
arguments = []
1914-
for name in argument_names:
1915-
arguments.append(getattr(self, name))
1913+
arguments = [getattr(self, name) for name in argument_names]
19161914
return check(*arguments)
19171915

19181916
def init_checker_state(self, name, argument_names):

0 commit comments

Comments
 (0)