mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-03-12 18:06:45 +08:00
Big diff: Use new "|" union syntax (#5872)
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import sys
|
||||
from threading import Condition, Lock
|
||||
from typing import Any, Generic, Optional, TypeVar
|
||||
from typing import Any, Generic, TypeVar
|
||||
|
||||
if sys.version_info >= (3, 9):
|
||||
from types import GenericAlias
|
||||
@@ -23,10 +23,10 @@ class Queue(Generic[_T]):
|
||||
def _init(self, maxsize: int) -> None: ...
|
||||
def empty(self) -> bool: ...
|
||||
def full(self) -> bool: ...
|
||||
def get(self, block: bool = ..., timeout: Optional[float] = ...) -> _T: ...
|
||||
def get(self, block: bool = ..., timeout: float | None = ...) -> _T: ...
|
||||
def get_nowait(self) -> _T: ...
|
||||
def _get(self) -> _T: ...
|
||||
def put(self, item: _T, block: bool = ..., timeout: Optional[float] = ...) -> None: ...
|
||||
def put(self, item: _T, block: bool = ..., timeout: float | None = ...) -> None: ...
|
||||
def put_nowait(self, item: _T) -> None: ...
|
||||
def _put(self, item: _T) -> None: ...
|
||||
def join(self) -> None: ...
|
||||
@@ -43,9 +43,9 @@ if sys.version_info >= (3, 7):
|
||||
class SimpleQueue(Generic[_T]):
|
||||
def __init__(self) -> None: ...
|
||||
def empty(self) -> bool: ...
|
||||
def get(self, block: bool = ..., timeout: Optional[float] = ...) -> _T: ...
|
||||
def get(self, block: bool = ..., timeout: float | None = ...) -> _T: ...
|
||||
def get_nowait(self) -> _T: ...
|
||||
def put(self, item: _T, block: bool = ..., timeout: Optional[float] = ...) -> None: ...
|
||||
def put(self, item: _T, block: bool = ..., timeout: float | None = ...) -> None: ...
|
||||
def put_nowait(self, item: _T) -> None: ...
|
||||
def qsize(self) -> int: ...
|
||||
if sys.version_info >= (3, 9):
|
||||
|
||||
Reference in New Issue
Block a user