Fix annotation shadowed by forward reference of preoprty in datetime constructor. (#2337)

This commit is contained in:
Dominik Gabi
2018-07-20 17:21:32 -07:00
committed by Jelle Zijlstra
parent b5bddc479d
commit 14fb9df49c

View File

@@ -81,7 +81,7 @@ class time:
resolution: ClassVar[timedelta]
def __init__(self, hour: int = ..., minute: int = ..., second: int = ..., microsecond: int = ...,
tzinfo: Optional[tzinfo] = ...) -> None: ...
tzinfo: Optional[_tzinfo] = ...) -> None: ...
@property
def hour(self) -> int: ...
@@ -179,11 +179,11 @@ class datetime:
if sys.version_info >= (3, 6):
def __init__(self, year: int, month: int, day: int, hour: int = ...,
minute: int = ..., second: int = ..., microsecond: int = ...,
tzinfo: Optional[tzinfo] = ..., *, fold: int = ...) -> None: ...
tzinfo: Optional[_tzinfo] = ..., *, fold: int = ...) -> None: ...
else:
def __init__(self, year: int, month: int, day: int, hour: int = ...,
minute: int = ..., second: int = ..., microsecond: int = ...,
tzinfo: Optional[tzinfo] = ...) -> None: ...
tzinfo: Optional[_tzinfo] = ...) -> None: ...
@property
def year(self) -> int: ...