From 3b30996733236dbf8fabb66de19dbc420f630e27 Mon Sep 17 00:00:00 2001 From: Ethan Date: Tue, 17 Jan 2017 09:49:41 -0800 Subject: [PATCH] Change ast's parse signature to return Module (#836) --- stdlib/2/ast.pyi | 2 +- stdlib/3/ast.pyi | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/stdlib/2/ast.pyi b/stdlib/2/ast.pyi index 95bda5480..244b23092 100644 --- a/stdlib/2/ast.pyi +++ b/stdlib/2/ast.pyi @@ -21,7 +21,7 @@ __version__ = ... # type: str PyCF_ONLY_AST = ... # type: int -def parse(source: Union[str, bytes], filename: Union[str, bytes] = ..., mode: str = ...) -> AST: ... +def parse(source: Union[str, bytes], filename: Union[str, bytes] = ..., mode: str = ...) -> Module: ... def copy_location(new_node: AST, old_node: AST) -> AST: ... def dump(node: AST, annotate_fields: bool = ..., include_attributes: bool = ...) -> str: ... def fix_missing_locations(node: AST) -> AST: ... diff --git a/stdlib/3/ast.pyi b/stdlib/3/ast.pyi index f9488c908..534567650 100644 --- a/stdlib/3/ast.pyi +++ b/stdlib/3/ast.pyi @@ -25,7 +25,7 @@ class NodeVisitor(): class NodeTransformer(NodeVisitor): def generic_visit(self, node: AST) -> None: ... -def parse(source: Union[str, bytes], filename: Union[str, bytes] = ..., mode: str = ...) -> AST: ... +def parse(source: Union[str, bytes], filename: Union[str, bytes] = ..., mode: str = ...) -> Module: ... def copy_location(new_node: AST, old_node: AST) -> AST: ... def dump(node: AST, annotate_fields: bool = ..., include_attributes: bool = ...) -> str: ... def fix_missing_locations(node: AST) -> AST: ...