module documentation

Undocumented

Class ElementTreeRepr Override ElementTree with added str representation.
Class SubsetTree construct a tree that start with the total subset, and children will be the subset of the parent node. In case where some set is subset to multiple node, it will insert to all of the nodes. Most of it is taken from: https://stackoverflow...
Class TempAttr Temporary set multiple attribute of an obj. Example: with TempAttr(node) as handler: handler.set_attr("temp", 2)
Function build_sub_list Undocumented
Function check_selected_operand check selected_operand in the results to see if they're matched :param results: can be list of (InferenceResult or dict) :return: bool
Function combine_inference_results Undocumented
Function compare_inferred_node Undocumented
Function compare_variable Undocumented
Function get_py_val_from_z3_val Undocumented
Function infer_product implementation of products of operand in binop/boolop/compare etc...
Function is_match_call Undocumented
Function is_subset cancel element in main container that is subset/superset to the container_checker
Function make_import_optional optionally import module, log the warning message if it's not imported
Function make_z3_boolvar Undocumented
Function make_z3_const Undocumented
Function methdispatch Undocumented
Function pairwise s -> (s0,s1), (s1,s2), (s2, s3), ...
Function strip_constant_node FOr ast const node, get the actual python const
Function temp_config Undocumented
Constant AST2Z3TYPE_MAP Undocumented
Constant ASTBOOL2Z3_MAP Undocumented
Constant Z3CONST_MAP Undocumented
def build_sub_list(sets): (source)

Undocumented

Parameters
sets:listUndocumented
def check_selected_operand(results): (source)

check selected_operand in the results to see if they're matched :param results: can be list of (InferenceResult or dict) :return: bool

def combine_inference_results(results): (source)

Undocumented

def compare_inferred_node(node, constant): (source)

Undocumented

def compare_variable(a, b): (source)

Undocumented

def get_py_val_from_z3_val(z3_result): (source)

Undocumented

def infer_product(*iterators, disable_caching=False): (source)

implementation of products of operand in binop/boolop/compare etc...

def is_match_call(node1, node2, context=None): (source)

Undocumented

Parameters
node1:nodes.BaseNodeUndocumented
node2Undocumented
contextUndocumented
Returns
boolUndocumented
def is_subset(main_container, container_checker): (source)

cancel element in main container that is subset/superset to the container_checker

Parameters
main_container:setUndocumented
container_checker:setUndocumented
Returns
setUndocumented
def make_import_optional(name, package=None, manager=None): (source)

optionally import module, log the warning message if it's not imported

def make_z3_boolvar(op, values): (source)

Undocumented

def make_z3_const(value): (source)

Undocumented

def methdispatch(func): (source)

Undocumented

def pairwise(iterable): (source)

s -> (s0,s1), (s1,s2), (s2, s3), ...

def strip_constant_node(node): (source)

FOr ast const node, get the actual python const

@contextlib.contextmanager
def temp_config(manager, config): (source)

Undocumented

AST2Z3TYPE_MAP = (source)

Undocumented

Value
{int: z3.Int, float: z3.Real, bool: z3.Bool, str: z3.String}
ASTBOOL2Z3_MAP = (source)

Undocumented

Value
{'or': z3.Or, 'and': z3.And}
Z3CONST_MAP = (source)

Undocumented

Value
{int: z3.IntVal, float: z3.RealVal, str: z3.StringVal, bool: z3.BoolVal}