Fix default parameter syntax.

Use 'x:bool = ...' instead of 'x:bool = True' or 'x:bool = False'.
This commit is contained in:
Matthias Kramm
2016-01-22 16:39:15 -08:00
parent c83f4b57c7
commit 25a3fac0fd
3 changed files with 17 additions and 17 deletions

View File

@@ -228,7 +228,7 @@ class unicode(basestring, Sequence[unicode]):
def rsplit(self, sep: unicode = ..., maxsplit: int = ...) -> List[unicode]: ...
def rstrip(self, chars: unicode = ...) -> unicode: ...
def split(self, sep: unicode = ..., maxsplit: int = ...) -> List[unicode]: ...
def splitlines(self, keepends: bool = False) -> List[unicode]: ...
def splitlines(self, keepends: bool = ...) -> List[unicode]: ...
def startswith(self, prefix: Union[unicode, Tuple[unicode, ...]], start: int = 0,
end: int = ...) -> bool: ...
def strip(self, chars: unicode = ...) -> unicode: ...
@@ -316,7 +316,7 @@ class str(basestring, Sequence[str]):
def split(self, sep: str = ..., maxsplit: int = ...) -> List[str]: ...
@overload
def split(self, sep: unicode, maxsplit: int = ...) -> List[unicode]: ...
def splitlines(self, keepends: bool = False) -> List[str]: ...
def splitlines(self, keepends: bool = ...) -> List[str]: ...
def startswith(self, prefix: Union[unicode, Tuple[unicode, ...]]) -> bool: ...
@overload
def strip(self, chars: str = ...) -> str: ...
@@ -390,7 +390,7 @@ class bytearray(Sequence[int]):
def rsplit(self, sep: str = ..., maxsplit: int = ...) -> List[bytearray]: ...
def rstrip(self, chars: str = ...) -> bytearray: ...
def split(self, sep: str = ..., maxsplit: int = ...) -> List[bytearray]: ...
def splitlines(self, keepends: bool = False) -> List[bytearray]: ...
def splitlines(self, keepends: bool = ...) -> List[bytearray]: ...
def startswith(self, prefix: Union[str, Tuple[str, ...]]) -> bool: ...
def strip(self, chars: str = ...) -> bytearray: ...
def swapcase(self) -> bytearray: ...
@@ -434,7 +434,7 @@ class bytearray(Sequence[int]):
def __ge__(self, x: str) -> bool: ...
class bool(int, SupportsInt, SupportsFloat):
def __init__(self, o: object = False) -> None: ...
def __init__(self, o: object = ...) -> None: ...
class slice:
start = 0
@@ -479,7 +479,7 @@ class list(MutableSequence[_T], Generic[_T]):
def insert(self, index: int, object: _T) -> None: ...
def remove(self, object: _T) -> None: ...
def reverse(self) -> None: ...
def sort(self, *, key: Callable[[_T], Any] = ..., reverse: bool = False) -> None: ...
def sort(self, *, key: Callable[[_T], Any] = ..., reverse: bool = ...) -> None: ...
def __len__(self) -> int: ...
def __iter__(self) -> Iterator[_T]: ...
@@ -716,7 +716,7 @@ def setattr(object: Any, name: unicode, value: Any) -> None: ...
def sorted(iterable: Iterable[_T], *,
cmp: Callable[[_T, _T], int] = ...,
key: Callable[[_T], Any] = ...,
reverse: bool = False) -> List[_T]: ...
reverse: bool = ...) -> List[_T]: ...
def sum(iterable: Iterable[_T], start: _T = ...) -> _T: ...
def unichr(i: int) -> unicode: ...
def vars(object: Any = ...) -> Dict[str, Any]: ...

View File

@@ -30,7 +30,7 @@ class HTTPResponse:
chunk_left = ... # type: Any
length = ... # type: Any
will_close = ... # type: Any
def __init__(self, sock, debuglevel=0, strict=0, method=None, buffering=False) -> None: ...
def __init__(self, sock, debuglevel=0, strict=0, method=None, buffering:bool=...) -> None: ...
def begin(self): ...
def close(self): ...
def isclosed(self): ...
@@ -58,7 +58,7 @@ class HTTPConnection:
def putheader(self, header, *values): ...
def endheaders(self, message_body=None): ...
def request(self, method, url, body=None, headers=...): ...
def getresponse(self, buffering=False): ...
def getresponse(self, buffering:bool=...): ...
class HTTP:
debuglevel = ... # type: Any
@@ -67,7 +67,7 @@ class HTTP:
def getfile(self): ...
file = ... # type: Any
headers = ... # type: Any
def getreply(self, buffering=False): ...
def getreply(self, buffering:bool=...): ...
def close(self): ...
class HTTPSConnection(HTTPConnection):