mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-09 13:34:58 +08:00
Backport many ParamSpec-related changes to Python 2 (#7054)
This commit is contained in:
@@ -1,7 +1,9 @@
|
||||
from types import CodeType, FrameType, TracebackType
|
||||
from typing import IO, Any, Callable, Iterable, Mapping, SupportsInt, TypeVar
|
||||
from typing_extensions import ParamSpec
|
||||
|
||||
_T = TypeVar("_T")
|
||||
_P = ParamSpec("_P")
|
||||
_TraceDispatch = Callable[[FrameType, str, Any], Any] # TODO: Recursive type
|
||||
_ExcInfo = tuple[type[BaseException], BaseException, FrameType]
|
||||
|
||||
@@ -61,7 +63,7 @@ class Bdb:
|
||||
def run(self, cmd: str | CodeType, globals: dict[str, Any] | None = ..., locals: Mapping[str, Any] | None = ...) -> None: ...
|
||||
def runeval(self, expr: str, globals: dict[str, Any] | None = ..., locals: Mapping[str, Any] | None = ...) -> None: ...
|
||||
def runctx(self, cmd: str | CodeType, globals: dict[str, Any] | None, locals: Mapping[str, Any] | None) -> None: ...
|
||||
def runcall(self, __func: Callable[..., _T], *args: Any, **kwds: Any) -> _T | None: ...
|
||||
def runcall(self, __func: Callable[_P, _T], *args: _P.args, **kwds: _P.kwargs) -> _T | None: ...
|
||||
|
||||
class Breakpoint:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user