mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-09 13:34:58 +08:00
Use PEP 604 syntax wherever possible (#7493)
This commit is contained in:
@@ -1,12 +1,12 @@
|
||||
from array import array
|
||||
from mmap import mmap
|
||||
from typing import Any, Text, Union
|
||||
from typing import Any, Text
|
||||
|
||||
class error(Exception): ...
|
||||
|
||||
_FmtType = Union[bytes, Text]
|
||||
_BufferType = Union[array[int], bytes, bytearray, buffer, memoryview, mmap]
|
||||
_WriteBufferType = Union[array[Any], bytearray, buffer, memoryview, mmap]
|
||||
_FmtType = bytes | Text
|
||||
_BufferType = array[int] | bytes | bytearray | buffer | memoryview | mmap
|
||||
_WriteBufferType = array[Any] | bytearray | buffer | memoryview | mmap
|
||||
|
||||
def pack(fmt: _FmtType, *v: Any) -> bytes: ...
|
||||
def pack_into(fmt: _FmtType, buffer: _WriteBufferType, offset: int, *v: Any) -> None: ...
|
||||
|
||||
Reference in New Issue
Block a user