module documentation

Module for some node classes. More nodes in scoped_nodes.py

Class BaseContainer Base class for Set, FrozenSet, Tuple and List.
Class LookupMixIn Mixin to look up a name in the right scope.
Class Pattern Base class for all Pattern nodes.
Class TryStar Class representing an :class:`ast.TryStar` node.
Type Alias AssignedStmtsCall Undocumented
Type Alias AssignedStmtsPossibleNode Undocumented
Type Alias InferBinaryOperation Undocumented
Type Alias InferLHS Undocumented
Type Alias InferUnaryOp Undocumented
Function _container_getitem Get a slice or an item, using the given *index*, for the given sequence.
Function _create_basic_elements Create a list of nodes to function as the elements of a new node.
Function _create_dict_items Create a list of node pairs to function as the items of a new dict node.
Function _find_arg Undocumented
Function _format_args Undocumented
Function _infer_slice Undocumented
Function _is_const Undocumented
Function _slice_value Get the value of the given slice index.
Constant _SLICE_SENTINEL Undocumented
Type Variable _BadOpMessageT Undocumented
Type Variable _NodesT Undocumented
AssignedStmtsPossibleNode = (source)

Undocumented

Value
Union['List', 'Tuple', 'AssignName', 'AssignAttr', None]
InferUnaryOp = (source)

Undocumented

Value
Callable[[_NodesT, str], ConstFactoryResult]
def _container_getitem(instance, elts, index, context: InferenceContext|None = None): (source)

Get a slice or an item, using the given *index*, for the given sequence.

def _create_basic_elements(value: Iterable[Any], node: (List|Set)|Tuple) -> list[NodeNG]: (source)

Create a list of nodes to function as the elements of a new node.

Create a list of node pairs to function as the items of a new dict node.

def _find_arg(argname, args, rec=False): (source)

Undocumented

def _format_args(args, defaults=None, annotations=None, skippable_names: set[str]|None = None) -> str: (source)

Undocumented

def _infer_slice(node, context: InferenceContext|None = None): (source)

Undocumented

def _is_const(value) -> bool: (source)

Undocumented

def _slice_value(index, context: InferenceContext|None = None): (source)

Get the value of the given slice index.

_SLICE_SENTINEL = (source)

Undocumented

Value
object()
_BadOpMessageT = (source)

Undocumented

Value
TypeVar('_BadOpMessageT',
        bound=util.BadOperationMessage)

Undocumented

Value
TypeVar('_NodesT',
        bound=NodeNG)