Add __new__ to time.struct_time (#1394)

This is needed because otherwise pytype uses the `__new__` inherited from the `NamedTuple` base class.
This commit is contained in:
rchen152 authored and Guido van Rossum committed 2017-06-06 15:36:01 -07:00
1 parent 0679e0232c
commit 16ec7cbdf0
2 files changed
+13

No files matched your search

+3
View File
@@ -17,6 +17,9 @@ class struct_time(NamedTuple('_struct_time',
def __init__(self, o: Tuple[int, int, int,
int, int, int,
int, int, int], _arg: Any = ...) -> None: ...
def __new__(cls, o: Tuple[int, int, int,
int, int, int,
int, int, int], _arg: Any = ...) -> struct_time: ...
_TIME_TUPLE = Tuple[int, int, int, int, int, int, int, int, int]