You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The following expression should type-check fine, right?
map(list, [{1}])
The intended use is to convert (iterables of) sets to (iterables of) lists, e.g. to support slicing.
I'm getting this error:
main.py:1: error: Argument 1 to "map" has incompatible type "Type[List[Any]]"; expected "Callable[[Set[int]], List[_T]]"
Found 1 error in 1 file (checked 1 source file)
As a workaround, the following passes with Python 3.9: map(list[int], [{1}])
On earlier Python versions, the following works: map(lambda i: list(i), [{1}])
The following expression should type-check fine, right?
The intended use is to convert (iterables of) sets to (iterables of) lists, e.g. to support slicing.
I'm getting this error:
This issue seems related to #3092.
The text was updated successfully, but these errors were encountered: