bisect: hi is Optional (#4063)

Shows up in 3.9 because of https://github.com/python/cpython/pull/20163

Co-authored-by: hauntsaninja <>
This commit is contained in:
Shantanu
2020-05-24 17:53:03 -07:00
committed by GitHub
parent 9c53756f9c
commit e560ce0f57

View File

@@ -1,9 +1,9 @@
"""Stub file for the '_bisect' module."""
from typing import Sequence, MutableSequence, TypeVar
from typing import Optional, Sequence, MutableSequence, TypeVar
_T = TypeVar('_T')
def bisect_left(a: Sequence[_T], x: _T, lo: int = ..., hi: int = ...) -> int: ...
def bisect_right(a: Sequence[_T], x: _T, lo: int = ..., hi: int = ...) -> int: ...
def insort_left(a: MutableSequence[_T], x: _T, lo: int = ..., hi: int = ...) -> None: ...
def insort_right(a: MutableSequence[_T], x: _T, lo: int = ..., hi: int = ...) -> None: ...
def bisect_left(a: Sequence[_T], x: _T, lo: int = ..., hi: Optional[int] = ...) -> int: ...
def bisect_right(a: Sequence[_T], x: _T, lo: int = ..., hi: Optional[int] = ...) -> int: ...
def insort_left(a: MutableSequence[_T], x: _T, lo: int = ..., hi: Optional[int] = ...) -> None: ...
def insort_right(a: MutableSequence[_T], x: _T, lo: int = ..., hi: Optional[int] = ...) -> None: ...