Avoid using string literals in type annotations (#2294)

This commit is contained in:
Yusuke Miyazaki
2018-07-03 12:23:29 +09:00
committed by Jelle Zijlstra
parent 25ad95de4f
commit 6192cce9d9
50 changed files with 175 additions and 175 deletions

View File

@@ -44,7 +44,7 @@ class FunctionType:
__globals__ = func_globals
__name__ = func_name
def __call__(self, *args: Any, **kwargs: Any) -> Any: ...
def __get__(self, obj: Optional[object], type: Optional[type]) -> 'UnboundMethodType': ...
def __get__(self, obj: Optional[object], type: Optional[type]) -> UnboundMethodType: ...
LambdaType = FunctionType
@@ -68,14 +68,14 @@ class GeneratorType:
gi_code = ... # type: CodeType
gi_frame = ... # type: FrameType
gi_running = ... # type: int
def __iter__(self) -> 'GeneratorType': ...
def __iter__(self) -> GeneratorType: ...
def close(self) -> None: ...
def next(self) -> Any: ...
def send(self, arg: Any) -> Any: ...
@overload
def throw(self, val: BaseException) -> Any: ...
@overload
def throw(self, typ: type, val: BaseException = ..., tb: 'TracebackType' = ...) -> Any: ...
def throw(self, typ: type, val: BaseException = ..., tb: TracebackType = ...) -> Any: ...
class ClassType: ...
class UnboundMethodType: