dialyzer_callgraph

Types


active_digraph() = {d, digraph:graph()}
                         | {e, ets:tid(), ets:tid()}

callgraph() =
            #callgraph{digraph = digraph:graph(),
                       active_digraph = undefined | active_digraph(),
                       esc = undefined | ets:tid(),
                       letrec_map = undefined | ets:tid(),
                       name_map = undefined | ets:tid(),
                       rev_name_map = undefined | ets:tid(),
                       rec_var_map = undefined | ets:tid(),
                       self_rec = undefined | ets:tid(),
                       calls = undefined | ets:tid(),
                       race_detection = boolean(),
                       race_data_server = pid()}

callgraph_edge() = {mfa_or_funlbl(), mfa_or_funlbl()}

label() = integer() >= 0

mfa_calls() = [mfa_call()]

mfa_or_funlbl() = label() | mfa()

mod_deps() = dict:dict(module(), [module()])

scc() = [mfa_or_funlbl()]

Functions


new() -> callgraph()

delete(Callgraph::callgraph()) -> true

all_nodes(Callgraph::callgraph()) -> [mfa()]

lookup_rec_var(Label::label(), Callgraph::callgraph()) -> error | {ok, mfa()}

lookup_letrec(Label::label(), Callgraph::callgraph()) -> error | {ok, label()}

lookup_call_site(Label::label(), Callgraph::callgraph()) -> error | {ok, [term()]}

lookup_name(Label::label(), Callgraph::callgraph()) -> error | {ok, mfa()}

lookup_label(MFA::mfa_or_funlbl(), Callgraph::callgraph()) -> error | {ok, integer()}

in_neighbours(Label::mfa_or_funlbl(), Callgraph::callgraph()) -> none | [mfa_or_funlbl(), ...]

is_self_rec(MfaOrLabel::mfa_or_funlbl(), Callgraph::callgraph()) -> boolean()

is_escaping(Label::label(), Callgraph::callgraph()) -> boolean()

add_edges(Edges::[callgraph_edge()], CG::callgraph()) -> ok

add_edges(Edges::[callgraph_edge()], MFAs::[mfa_or_funlbl()], Callgraph::callgraph()) -> ok

remove_external(Callgraph::callgraph()) -> {callgraph(), [tuple()]}

non_local_calls(Callgraph::callgraph()) -> mfa_calls()

get_depends_on(SCC::scc() | module(), Callgraph::callgraph()) -> [scc()]

get_required_by(SCC::scc() | module(), Callgraph::callgraph()) -> [scc()]

modules(Callgraph::callgraph()) -> [module()]

module_deps(Callgraph::callgraph()) -> mod_deps()

strip_module_deps(ModDeps::mod_deps(), StripSet::set(module()) (see module sets)) -> mod_deps()

finalize(Callgraph::callgraph()) -> {[scc()], callgraph()}

reset_from_funs(Funs::[mfa_or_funlbl()], Callgraph::callgraph()) -> {[scc()], callgraph()}

module_postorder_from_funs(Funs::[mfa_or_funlbl()], Callgraph::callgraph()) -> {[module()], callgraph()}

scan_core_tree(Tree::c_module() (see module cerl), Callgraph::callgraph()) -> {[mfa_or_funlbl()], [callgraph_edge()]}

renew_race_info(Callgraph::callgraph(), RaceCode::dict() (see module dict), PublicTables::[label()], NamedTables::[string()]) -> callgraph()

renew_race_code(Races::races() (see module dialyzer_races), Callgraph::callgraph()) -> callgraph()

renew_race_public_tables(VarLabel::label(), Callgraph::callgraph()) -> callgraph()

cleanup(Callgraph::callgraph()) -> callgraph()

duplicate(Callgraph::callgraph()) -> callgraph()

dispose_race_server(Callgraph::callgraph()) -> ok

get_digraph(Callgraph::callgraph()) -> graph() (see module digraph)

get_named_tables(Callgraph::callgraph()) -> [string()]

get_public_tables(Callgraph::callgraph()) -> [label()]

get_race_code(Callgraph::callgraph()) -> dict() (see module dict)

get_race_detection(Callgraph::callgraph()) -> boolean()

get_behaviour_api_calls(Callgraph::callgraph()) -> [{mfa(), mfa()}]

race_code_new(Callgraph::callgraph()) -> callgraph()

put_digraph(Digraph::graph() (see module digraph), Callgraph::callgraph()) -> callgraph()

put_race_code(RaceCode::dict() (see module dict), Callgraph::callgraph()) -> callgraph()

put_race_detection(RaceDetection::boolean(), Callgraph::callgraph()) -> callgraph()

put_named_tables(NamedTables::[string()], Callgraph::callgraph()) -> callgraph()

put_public_tables(PublicTables::[label()], Callgraph::callgraph()) -> callgraph()

put_behaviour_api_calls(Calls::[{mfa(), mfa()}], Callgraph::callgraph()) -> callgraph()

to_dot(Callgraph::callgraph(), File::filename() (see module file)) -> ok

to_ps(Callgraph::callgraph(), File::filename() (see module file), Args::string()) -> ok