Break cycle between typing and collections. (Requires a fix in mypy.)

This commit is contained in:
Guido van Rossum
2016-04-15 21:31:49 -07:00
parent e8a477d69d
commit 23ec1ff96a
2 changed files with 2 additions and 4 deletions

View File

@@ -1,7 +1,6 @@
# Stubs for typing (Python 2.7)
from abc import abstractmethod, ABCMeta
import collections
# Definitions of special type checking related constructs. Their definition
# are not used, so their value does not matter.
@@ -28,7 +27,7 @@ Union = TypeAlias(object)
Optional = TypeAlias(object)
List = TypeAlias(object)
Dict = TypeAlias(object)
DefaultDict = collections.defaultdict
DefaultDict = TypeAlias(object)
Set = TypeAlias(object)
# Predefined type variables.

View File

@@ -1,7 +1,6 @@
# Stubs for typing
from abc import abstractmethod, ABCMeta
import collections
# Definitions of special type checking related constructs. Their definition
# are not used, so their value does not matter.
@@ -29,7 +28,7 @@ Union = TypeAlias(object)
Optional = TypeAlias(object)
List = TypeAlias(object)
Dict = TypeAlias(object)
DefaultDict = collections.defaultdict
DefaultDict = TypeAlias(object)
Set = TypeAlias(object)
# Predefined type variables.