module documentation

Code and data structures for managing source directives.

Class Director Holds all of the directive information for a source file.
Variable log Undocumented
Class _BlockRanges A collection of possibly nested start..end ranges from AST nodes.
Class _LineSet A set of line numbers.
Class _OpcodeLines Stores opcode line numbers for Director.adjust_line_numbers().
Exception _DirectiveError Undocumented
Function _adjust_line_number Undocumented
Function _collect_bytecode Undocumented
Function _is_function_call Undocumented
Function _is_load_attribute_op Checks whether the opcode loads an attribute.
Function _is_return_op Undocumented
Constant _ALL_ADJUSTABLE_ERRORS Undocumented
Constant _ALL_ERRORS Undocumented
Constant _ALLOWED_FEATURES Undocumented
Constant _FUNCTION_CALL_ERRORS Undocumented

Undocumented

def _adjust_line_number(line, allowed_lines, min_line): (source)

Undocumented

def _collect_bytecode(ordered_code): (source)

Undocumented

def _is_function_call(opcode_name): (source)

Undocumented

def _is_load_attribute_op(opcode_name): (source)

Checks whether the opcode loads an attribute.

def _is_return_op(opcode_name): (source)

Undocumented

_ALL_ADJUSTABLE_ERRORS = (source)

Undocumented

Value
_FUNCTION_CALL_ERRORS.union(('annotation-type-mismatch',
                             'bad-return-type',
                             'bad-yield-annotation',
                             'container-type-mismatch',
                             'not-supported-yet',
                             'signature-mismatch'))
_ALL_ERRORS: str = (source)

Undocumented

Value
'*'
_ALLOWED_FEATURES = (source)

Undocumented

Value
frozenset((x.flag for x in config.FEATURE_FLAGS))
_FUNCTION_CALL_ERRORS = (source)

Undocumented

Value
frozenset(('attribute-error',
           'duplicate-keyword',
           'invalid-annotation',
           'missing-parameter',
           'not-instantiable',
           'wrong-arg-count',
           'wrong-arg-types',
...