Add correct optional default start/end parameters to str count, find, index, rfind, rindex. (#1109)

fixes #1108
This commit is contained in:
George King
2017-03-28 13:11:50 -04:00
committed by Guido van Rossum
parent 03bfcee0b8
commit 18cc2cbf8c
2 changed files with 10 additions and 10 deletions

View File

@@ -221,15 +221,15 @@ class str(Sequence[str]):
def __init__(self, o: bytes, encoding: str = ..., errors: str = 'strict') -> None: ...
def capitalize(self) -> str: ...
def center(self, width: int, fillchar: str = ' ') -> str: ...
def count(self, x: str) -> int: ...
def count(self, x: str, __start: Optional[int] = ..., __end: Optional[int] = ...) -> int: ...
def encode(self, encoding: str = 'utf-8', errors: str = 'strict') -> bytes: ...
def endswith(self, suffix: Union[str, Tuple[str, ...]], start: int = None,
end: int = None) -> bool: ...
def expandtabs(self, tabsize: int = 8) -> str: ...
def find(self, sub: str, start: int = 0, end: int = 0) -> int: ...
def find(self, sub: str, __start: Optional[int] = ..., __end: Optional[int] = ...) -> int: ...
def format(self, *args: Any, **kwargs: Any) -> str: ...
def format_map(self, map: Mapping[str, Any]) -> str: ...
def index(self, sub: str, start: int = 0, end: int = 0) -> int: ...
def index(self, sub: str, __start: Optional[int] = ..., __end: Optional[int] = ...) -> int: ...
def isalnum(self) -> bool: ...
def isalpha(self) -> bool: ...
def isdecimal(self) -> bool: ...
@@ -247,8 +247,8 @@ class str(Sequence[str]):
def lstrip(self, chars: str = None) -> str: ...
def partition(self, sep: str) -> Tuple[str, str, str]: ...
def replace(self, old: str, new: str, count: int = -1) -> str: ...
def rfind(self, sub: str, start: int = 0, end: int = 0) -> int: ...
def rindex(self, sub: str, start: int = 0, end: int = 0) -> int: ...
def rfind(self, sub: str, __start: Optional[int] = ..., __end: Optional[int] = ...) -> int: ...
def rindex(self, sub: str, __start: Optional[int] = ..., __end: Optional[int] = ...) -> int: ...
def rjust(self, width: int, fillchar: str = ' ') -> str: ...
def rpartition(self, sep: str) -> Tuple[str, str, str]: ...
def rsplit(self, sep: str = None, maxsplit: int = -1) -> List[str]: ...