module documentation
Undocumented
Class |
|
No class docstring; 0/7 instance variable, 0/2 constant, 6/98 methods documented |
Class |
|
No class docstring; 0/5 instance variable, 4/27 methods documented |
Function | ast3 |
Undocumented |
Function | is |
Undocumented |
Function | parse |
Parse a source file, without doing any semantic analysis. |
Function | parse |
Parse type portion of a type comment (+ optional type ignore). |
Function | parse |
Parse optional "[code, ...]" tag after "# type: ignore". |
Function | parse |
Parses a type that was originally present inside of an explicit string. |
Function | stringify |
Undocumented |
Constant | INVALID |
Undocumented |
Constant | MISSING |
Undocumented |
Constant | PY |
Undocumented |
Constant | TYPE |
Undocumented |
Constant | TYPE |
Undocumented |
Type Variable | N |
Undocumented |
Type Alias |
|
Undocumented |
Constant | _dummy |
Undocumented |
def ast3_parse(source:
str|bytes
, filename: str
, mode: str
, feature_version: int
= PY_MINOR_VERSION) -> AST
:
(source)
¶
Undocumented
def parse(source:
str|bytes
, fnam: str
, module: str|None
, errors: Errors|None
= None, options: Options|None
= None) -> MypyFile
:
(source)
¶
Parse a source file, without doing any semantic analysis. Return the parse tree. If errors is not provided, raise ParseError on failure. Otherwise, use the errors object to report parse errors.
def parse_type_comment(type_comment:
str
, line: int
, column: int
, errors: Errors|None
) -> tuple[ list[ str]|None, ProperType|None]
:
(source)
¶
Parse type portion of a type comment (+ optional type ignore). Return (ignore info, parsed type).
Parse optional "[code, ...]" tag after "# type: ignore". Return: * [] if no tag was found (ignore all errors) * list of ignored error codes if a tag was found * None if the tag was invalid.
def parse_type_string(expr_string:
str
, expr_fallback_name: str
, line: int
, column: int
) -> ProperType
:
(source)
¶
Parses a type that was originally present inside of an explicit string. For example, suppose we have the type `Foo["blah"]`. We should parse the string expression "blah" using this function.