Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Address review
  • Loading branch information
sobolevn committed Mar 14, 2023
commit a461b10a5977101c76c665f2be1a9a819f9f6cd7
4 changes: 3 additions & 1 deletion Lib/_collections_abc.py
Original file line number Diff line number Diff line change
Expand Up @@ -501,7 +501,9 @@ def __getitem__(self, item):

# This happens in cases like `Callable[P, T][[P, str], bool][int]`,
# we need to flatten the result.
if len(new_args) > 2:
if (len(new_args) > 2
and self.__parameters__
and _is_param_expr(self.__parameters__[0])):
res = []
for new_arg in new_args:
if isinstance(new_arg, tuple):
Expand Down