mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-01-24 20:12:08 +08:00
Use _typeshed.Self with __enter__ (#5723)
Co-authored-by: Sebastian Rittau <srittau@rittau.biz> Co-authored-by: Akuli <akuviljanen17@gmail.com>
This commit is contained in:
@@ -6,6 +6,7 @@ from _typeshed import (
|
||||
OpenBinaryModeUpdating,
|
||||
OpenBinaryModeWriting,
|
||||
OpenTextMode,
|
||||
Self,
|
||||
StrOrBytesPath,
|
||||
StrPath,
|
||||
)
|
||||
@@ -860,7 +861,7 @@ if sys.version_info >= (3, 8):
|
||||
path: Optional[str]
|
||||
def __init__(self, path: Optional[str], cookie: _T, remove_dll_directory: Callable[[_T], Any]) -> None: ...
|
||||
def close(self) -> None: ...
|
||||
def __enter__(self: _T) -> _T: ...
|
||||
def __enter__(self: Self) -> Self: ...
|
||||
def __exit__(self, *args: Any) -> None: ...
|
||||
def add_dll_directory(path: str) -> _AddedDllDirectory: ...
|
||||
if sys.platform == "linux":
|
||||
|
||||
Reference in New Issue
Block a user