Function | arguments_assigned_stmts |
Undocumented |
Function | assend_assigned_stmts |
Undocumented |
Function | assign_annassigned_stmts |
Undocumented |
Function | assign_assigned_stmts |
Undocumented |
Function | const_infer_binary_op |
Undocumented |
Function | excepthandler_assigned_stmts |
Undocumented |
Function | for_assigned_stmts |
Undocumented |
Function | instance_class_infer_binary_op |
Undocumented |
Function | match_as_assigned_stmts |
Infer MatchAs as the Match subject if it's the only MatchCase pattern else raise StopIteration to yield Uninferable. |
Function | match_mapping_assigned_stmts |
Return empty generator (return -> raises StopIteration) so inferred value is Uninferable. |
Function | match_star_assigned_stmts |
Return empty generator (return -> raises StopIteration) so inferred value is Uninferable. |
Function | named_expr_assigned_stmts |
Infer names and other nodes from an assignment expression |
Function | sequence_assigned_stmts |
Undocumented |
Function | starred_assigned_stmts |
No summary |
Function | tl_infer_binary_op |
Undocumented |
Function | with_assigned_stmts |
Infer names and other nodes from a with statement. |
Constant | AUGMENTED_OP_METHOD |
Undocumented |
Constant | BIN_OP_IMPL |
Undocumented |
Constant | BIN_OP_METHOD |
Undocumented |
Constant | REFLECTED_BIN_OP_METHOD |
Undocumented |
Constant | UNARY_OP_METHOD |
Undocumented |
Variable | objects |
Undocumented |
Variable | raw_building |
Undocumented |
Function | _arguments_infer_argname |
Undocumented |
Function | _augmented_name |
Undocumented |
Function | _filter_uninferable_nodes |
Undocumented |
Function | _infer_context_manager |
Undocumented |
Function | _infer_unary_op |
Undocumented |
Function | _multiply_seq_by_int |
Undocumented |
Function | _reflected_name |
Undocumented |
Function | _resolve_assignment_parts |
recursive function to resolve multiple assignments |
Function | _resolve_looppart |
recursive function to resolve multiple assignments on loops |
Constant | _CONTEXTLIB_MGR |
Undocumented |
Constant | _UNARY_OPERATORS |
Undocumented |
Undocumented
Parameters | |
node:node_classes.AssignedStmtsPossibleNode | Undocumented |
context:Optional[ | Undocumented |
assign_path:Optional[ | Undocumented |
Returns | |
Any | Undocumented |
Undocumented
Parameters | |
node:node_classes.AssignedStmtsPossibleNode | Undocumented |
context:Optional[ | Undocumented |
assign_path:Optional[ | Undocumented |
Returns | |
Any | Undocumented |
Undocumented
Parameters | |
node:node_classes.AssignedStmtsPossibleNode | Undocumented |
context:Optional[ | Undocumented |
assign_path:Optional[ | Undocumented |
Returns | |
Any | Undocumented |
Undocumented
Parameters | |
node:node_classes.AssignedStmtsPossibleNode | Undocumented |
context:Optional[ | Undocumented |
assign_path:Optional[ | Undocumented |
Returns | |
Any | Undocumented |
Undocumented
Undocumented
Parameters | |
node:node_classes.AssignedStmtsPossibleNode | Undocumented |
context:Optional[ | Undocumented |
assign_path:Optional[ | Undocumented |
Returns | |
Any | Undocumented |
Undocumented
Parameters | |
node:node_classes.AssignedStmtsPossibleNode | Undocumented |
context:Optional[ | Undocumented |
assign_path:Optional[ | Undocumented |
Returns | |
Any | Undocumented |
Undocumented
Parameters | |
node:nodes.AssignName | Undocumented |
context:Optional[ | Undocumented |
assign_path:Literal[ | Undocumented |
Returns | |
Generator[ | Undocumented |
Parameters | |
node:nodes.AssignName | Undocumented |
context:Optional[ | Undocumented |
assign_path:Literal[ | Undocumented |
Returns | |
Generator[ | Undocumented |
Parameters | |
node:nodes.AssignName | Undocumented |
context:Optional[ | Undocumented |
assign_path:Literal[ | Undocumented |
Returns | |
Generator[ | Undocumented |
Parameters | |
node:node_classes.AssignedStmtsPossibleNode | Undocumented |
context:Optional[ | Undocumented |
assign_path:Optional[ | Undocumented |
Returns | |
Any | Undocumented |
Undocumented
Parameters | |
node:node_classes.AssignedStmtsPossibleNode | Undocumented |
context:Optional[ | Undocumented |
assign_path:Optional[ | Undocumented |
Returns | |
Any | Undocumented |
self: nodes.Starred node: a node related to the current underlying Node. context: Inference context used for caching already inferred objects assign_path:
A list of indices, where each index specifies what item to fetch from the inference results.
Parameters | |
node:node_classes.AssignedStmtsPossibleNode | Undocumented |
context:Optional[ | Undocumented |
assign_path:Optional[ | Undocumented |
Returns | |
Any | Undocumented |
Undocumented
Infer names and other nodes from a with statement.
This enables only inference for name binding in a with statement.
For instance, in the following code, inferring func
will return
the ContextManager
class, not whatever __enter__ returns.
We are doing this intentionally, because we consider that the context
manager result is whatever __enter__ returns and what it is binded
using the as keyword.
- class ContextManager(object):
- def __enter__(self):
- return 42
- with ContextManager() as f:
- pass
# ContextManager().infer() will return ContextManager # f.infer() will return 42.
self: nodes.With
node: The target of the assignment, as (a, b)
in with foo as (a, b)
.
context: Inference context used for caching already inferred objects
assign_path:
A list of indices, where each index specifies what item to fetch from the inference results.
Parameters | |
node:node_classes.AssignedStmtsPossibleNode | Undocumented |
context:Optional[ | Undocumented |
assign_path:Optional[ | Undocumented |
Returns | |
Any | Undocumented |
Undocumented
Value |
|
Undocumented
Value |
|
Undocumented
Value |
|
Undocumented
Value |
|
Undocumented
Value |
|