Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace list comprehension with generator expresion when calling any() #604

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion pytype/pyi/parser.py
Expand Up @@ -985,7 +985,7 @@ def new_function(
# Extract out abstractmethod and coroutine decorators, there should be at
# most one remaining decorator.
def _check_decorator(decorators, decorator_set):
exists = any([x in decorators for x in decorator_set])
exists = any(x in decorators for x in decorator_set)
if exists:
decorators -= decorator_set
return exists
Expand Down