module documentation

Undocumented

Function path_wrapper Return the given infer function wrapped to handle the path
Function raise_if_nothing_inferred Return the given infer function wrapped to raise InferenceError if the generator is empty.
Function yes_if_nothing_inferred Return the given infer function wrapped to yield Uninferable if the generator is empty.
@decorator
def path_wrapper(func, node, context): (source)

Return the given infer function wrapped to handle the path

Used to stop inference if the node has already been looked at for a given InferenceContext to prevent infinite recursion.

Parameters
func:_InferMethTUndocumented
node:ASTNodeTUndocumented
context:OptionalInferenceContextUndocumented
Returns
InferResultUndocumented
@decorator
def raise_if_nothing_inferred(func, node, *args, **kwargs): (source)

Return the given infer function wrapped to raise InferenceError if the generator is empty.

Parameters
func:_InferMethTUndocumented
node:ASTNodeTUndocumented
*args:AnyUndocumented
**kwargs:AnyUndocumented
Returns
InferResultUndocumented
@decorator
def yes_if_nothing_inferred(func, node, *args, **kwargs): (source)

Return the given infer function wrapped to yield Uninferable if the generator is empty.

Parameters
func:_InferMethTUndocumented
node:ASTNodeTUndocumented
*args:AnyUndocumented
**kwargs:AnyUndocumented
Returns
InferResultUndocumented