mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-09 21:46:42 +08:00
Use PEP 604 syntax wherever possible (#7493)
This commit is contained in:
@@ -2,7 +2,7 @@ import sys
|
||||
from _typeshed import structseq
|
||||
from enum import IntEnum
|
||||
from types import FrameType
|
||||
from typing import Any, Callable, Iterable, Optional, Union
|
||||
from typing import Any, Callable, Iterable, Union
|
||||
from typing_extensions import final
|
||||
|
||||
NSIG: int
|
||||
@@ -60,8 +60,8 @@ class Handlers(IntEnum):
|
||||
SIG_DFL: Handlers
|
||||
SIG_IGN: Handlers
|
||||
|
||||
_SIGNUM = Union[int, Signals]
|
||||
_HANDLER = Union[Callable[[int, Optional[FrameType]], Any], int, Handlers, None]
|
||||
_SIGNUM = int | Signals
|
||||
_HANDLER = Union[Callable[[int, FrameType | None], Any], int, Handlers, None]
|
||||
|
||||
def default_int_handler(__signalnum: int, __frame: FrameType | None) -> None: ...
|
||||
|
||||
|
||||
Reference in New Issue
Block a user