mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-01-09 13:02:22 +08:00
apply black and isort (#4287)
* apply black and isort * move some type ignores
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
from array import array
|
||||
from typing import Any, Union, overload
|
||||
|
||||
from typing_extensions import Literal
|
||||
|
||||
from _typeshed import FileDescriptorLike
|
||||
|
||||
FASYNC: int
|
||||
@@ -75,40 +77,20 @@ LOCK_RW: int
|
||||
LOCK_SH: int
|
||||
LOCK_UN: int
|
||||
LOCK_WRITE: int
|
||||
@overload
|
||||
def fcntl(__fd: FileDescriptorLike, __cmd: int, __arg: int = ...) -> int: ...
|
||||
@overload
|
||||
def fcntl(__fd: FileDescriptorLike, __cmd: int, __arg: bytes) -> bytes: ...
|
||||
|
||||
@overload
|
||||
def fcntl(__fd: FileDescriptorLike,
|
||||
__cmd: int,
|
||||
__arg: int = ...) -> int: ...
|
||||
@overload
|
||||
def fcntl(__fd: FileDescriptorLike,
|
||||
__cmd: int,
|
||||
__arg: bytes) -> bytes: ...
|
||||
_ReadOnlyBuffer = bytes
|
||||
_WritableBuffer = Union[bytearray, memoryview, array]
|
||||
@overload
|
||||
def ioctl(__fd: FileDescriptorLike,
|
||||
__request: int,
|
||||
__arg: int = ...,
|
||||
__mutate_flag: bool = ...) -> int: ...
|
||||
def ioctl(__fd: FileDescriptorLike, __request: int, __arg: int = ..., __mutate_flag: bool = ...) -> int: ...
|
||||
@overload
|
||||
def ioctl(__fd: FileDescriptorLike,
|
||||
__request: int,
|
||||
__arg: _WritableBuffer,
|
||||
__mutate_flag: Literal[True] = ...) -> int: ...
|
||||
def ioctl(__fd: FileDescriptorLike, __request: int, __arg: _WritableBuffer, __mutate_flag: Literal[True] = ...) -> int: ...
|
||||
@overload
|
||||
def ioctl(__fd: FileDescriptorLike,
|
||||
__request: int,
|
||||
__arg: _WritableBuffer,
|
||||
__mutate_flag: Literal[False]) -> bytes: ...
|
||||
def ioctl(__fd: FileDescriptorLike, __request: int, __arg: _WritableBuffer, __mutate_flag: Literal[False]) -> bytes: ...
|
||||
@overload
|
||||
def ioctl(__fd: FileDescriptorLike,
|
||||
__request: int,
|
||||
__arg: _ReadOnlyBuffer,
|
||||
__mutate_flag: bool = ...) -> bytes: ...
|
||||
def ioctl(__fd: FileDescriptorLike, __request: int, __arg: _ReadOnlyBuffer, __mutate_flag: bool = ...) -> bytes: ...
|
||||
def flock(__fd: FileDescriptorLike, __operation: int) -> None: ...
|
||||
def lockf(__fd: FileDescriptorLike,
|
||||
__cmd: int,
|
||||
__len: int = ...,
|
||||
__start: int = ...,
|
||||
__whence: int = ...) -> Any: ...
|
||||
def lockf(__fd: FileDescriptorLike, __cmd: int, __len: int = ..., __start: int = ..., __whence: int = ...) -> Any: ...
|
||||
|
||||
Reference in New Issue
Block a user