mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-07 04:34:28 +08:00
stream argument to pprint.pprint is Optional (#3488)
None is the default; see https://docs.python.org/3/library/pprint.html#pprint.PrettyPrinter
This commit is contained in:
committed by
Sebastian Rittau
parent
91f445ef11
commit
a89f883878
@@ -14,10 +14,10 @@ else:
|
||||
depth: Optional[int] = ...) -> str: ...
|
||||
|
||||
if sys.version_info >= (3, 4):
|
||||
def pprint(o: object, stream: IO[str] = ..., indent: int = ..., width: int = ...,
|
||||
def pprint(o: object, stream: Optional[IO[str]] = ..., indent: int = ..., width: int = ...,
|
||||
depth: Optional[int] = ..., compact: bool = ...) -> None: ...
|
||||
else:
|
||||
def pprint(o: object, stream: IO[str] = ..., indent: int = ..., width: int = ...,
|
||||
def pprint(o: object, stream: Optional[IO[str]] = ..., indent: int = ..., width: int = ...,
|
||||
depth: Optional[int] = ...) -> None: ...
|
||||
|
||||
def isreadable(o: object) -> bool: ...
|
||||
@@ -27,10 +27,10 @@ def saferepr(o: object) -> str: ...
|
||||
class PrettyPrinter:
|
||||
if sys.version_info >= (3, 4):
|
||||
def __init__(self, indent: int = ..., width: int = ..., depth: Optional[int] = ...,
|
||||
stream: IO[str] = ..., compact: bool = ...) -> None: ...
|
||||
stream: Optional[IO[str]] = ..., compact: bool = ...) -> None: ...
|
||||
else:
|
||||
def __init__(self, indent: int = ..., width: int = ..., depth: Optional[int] = ...,
|
||||
stream: IO[str] = ...) -> None: ...
|
||||
stream: Optional[IO[str]] = ...) -> None: ...
|
||||
|
||||
def pformat(self, o: object) -> str: ...
|
||||
def pprint(self, o: object) -> None: ...
|
||||
|
||||
Reference in New Issue
Block a user