mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-10-08 05:04:44 +08:00
Use typing_extensions.Self in the stdlib (#9694)
This commit is contained in:
1 parent
10086c06a1
commit
9ed39d8796
98 files changed
+627
-654
No files matched your search
+4
-4
@@ -1,7 +1,7 @@
|
||||
import sys
|
||||
from _typeshed import Self, Unused
|
||||
from _typeshed import Unused
|
||||
from typing import IO, Any, NamedTuple, NoReturn, overload
|
||||
from typing_extensions import Literal, TypeAlias
|
||||
from typing_extensions import Literal, Self, TypeAlias
|
||||
|
||||
_File: TypeAlias = str | IO[bytes]
|
||||
|
||||
@@ -32,7 +32,7 @@ class _sunau_params(NamedTuple):
|
||||
|
||||
class Au_read:
|
||||
def __init__(self, f: _File) -> None: ...
|
||||
def __enter__(self: Self) -> Self: ...
|
||||
def __enter__(self) -> Self: ...
|
||||
def __exit__(self, *args: Unused) -> None: ...
|
||||
def getfp(self) -> IO[bytes] | None: ...
|
||||
def rewind(self) -> None: ...
|
||||
@@ -52,7 +52,7 @@ class Au_read:
|
||||
|
||||
class Au_write:
|
||||
def __init__(self, f: _File) -> None: ...
|
||||
def __enter__(self: Self) -> Self: ...
|
||||
def __enter__(self) -> Self: ...
|
||||
def __exit__(self, *args: Unused) -> None: ...
|
||||
def setnchannels(self, nchannels: int) -> None: ...
|
||||
def getnchannels(self) -> int: ...
|
||||
|
||||
Reference in new issue
Block a user