You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

3 lines
6.8 KiB

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml"><head><title>InferModules__Callbacks (infer.InferModules__Callbacks)</title><link rel="stylesheet" href="../../odoc.css"/><meta charset="utf-8"/><meta name="viewport" content="width=device-width,initial-scale=1.0"/><meta name="generator" content="doc-ock-html v1.0.0-1-g1fc9bf0"/></head><body><nav id="top"><a href="../index.html">Up</a> &mdash; <span class="package">package <a href="../index.html">infer</a></span></nav><header><h1><span class="keyword">Module</span> <span class="module-path">InferModules__Callbacks</span></h1></header><p>Module to register and invoke callbacks</p><div class="spec type" id="type-proc_callback_args"><a href="#type-proc_callback_args" class="anchor"></a><div class="def type"><code><span class="keyword">type </span>proc_callback_args</code><code></code><code><span class="keyword"> = </span></code><code>{</code><table class="record"><tr id="type-proc_callback_args.get_proc_desc" class="anchored"><td class="def field"><a href="#type-proc_callback_args.get_proc_desc" class="anchor"></a><code>get_proc_desc : <a href="../../InferIR/InferIR/Typ/Procname/index.html#type-t">InferIR.Typ.Procname.t</a> <span class="keyword">&#8209;&gt;</span> <a href="../../InferIR/InferIR/Procdesc/index.html#type-t">InferIR.Procdesc.t</a> option;</code></td></tr><tr id="type-proc_callback_args.get_procs_in_file" class="anchored"><td class="def field"><a href="#type-proc_callback_args.get_procs_in_file" class="anchor"></a><code>get_procs_in_file : <a href="../../InferIR/InferIR/Typ/Procname/index.html#type-t">InferIR.Typ.Procname.t</a> <span class="keyword">&#8209;&gt;</span> <a href="../../InferIR/InferIR/Typ/Procname/index.html#type-t">InferIR.Typ.Procname.t</a> list;</code></td></tr><tr id="type-proc_callback_args.tenv" class="anchored"><td class="def field"><a href="#type-proc_callback_args.tenv" class="anchor"></a><code>tenv : <a href="../../InferIR/InferIR/Tenv/index.html#type-t">InferIR.Tenv.t</a>;</code></td></tr><tr id="type-proc_callback_args.summary" class="anchored"><td class="def field"><a href="#type-proc_callback_args.summary" class="anchor"></a><code>summary : <a href="../InferModules/Summary/index.html#type-t">InferModules.Summary.t</a>;</code></td></tr><tr id="type-proc_callback_args.proc_desc" class="anchored"><td class="def field"><a href="#type-proc_callback_args.proc_desc" class="anchor"></a><code>proc_desc : <a href="../../InferIR/InferIR/Procdesc/index.html#type-t">InferIR.Procdesc.t</a>;</code></td></tr><tr id="type-proc_callback_args.exe_env" class="anchored"><td class="def field"><a href="#type-proc_callback_args.exe_env" class="anchor"></a><code>exe_env : <a href="../InferModules/Exe_env/index.html#type-t">InferModules.Exe_env.t</a>;</code></td></tr></table><code>}</code><code></code></div><div class="doc"></div></div><div class="spec type" id="type-proc_callback_t"><a href="#type-proc_callback_t" class="anchor"></a><div class="def type"><code><span class="keyword">type </span>proc_callback_t</code><code><span class="keyword"> = </span><a href="index.html#type-proc_callback_args">proc_callback_args</a> <span class="keyword">&#8209;&gt;</span> <a href="../InferModules/Summary/index.html#type-t">InferModules.Summary.t</a></code><code></code></div><div class="doc"><p>Type of a procedure callback:
</p><ul><li>List of all the procedures the callback will be called on.</li><li>get_proc_desc to get a proc desc from a proc name</li><li>Type environment.</li><li>Procedure for the callback to act on.</li></ul></div></div><div class="spec type" id="type-cluster_callback_args"><a href="#type-cluster_callback_args" class="anchor"></a><div class="def type"><code><span class="keyword">type </span>cluster_callback_args</code><code></code><code><span class="keyword"> = </span></code><code>{</code><table class="record"><tr id="type-cluster_callback_args.procedures" class="anchored"><td class="def field"><a href="#type-cluster_callback_args.procedures" class="anchor"></a><code>procedures : (<a href="../../InferIR/InferIR/Tenv/index.html#type-t">InferIR.Tenv.t</a><span class="keyword"> * </span><a href="../../InferIR/InferIR/Procdesc/index.html#type-t">InferIR.Procdesc.t</a>) list;</code></td></tr><tr id="type-cluster_callback_args.get_proc_desc" class="anchored"><td class="def field"><a href="#type-cluster_callback_args.get_proc_desc" class="anchor"></a><code>get_proc_desc : <a href="../../InferIR/InferIR/Typ/Procname/index.html#type-t">InferIR.Typ.Procname.t</a> <span class="keyword">&#8209;&gt;</span> <a href="../../InferIR/InferIR/Procdesc/index.html#type-t">InferIR.Procdesc.t</a> option;</code></td></tr><tr id="type-cluster_callback_args.exe_env" class="anchored"><td class="def field"><a href="#type-cluster_callback_args.exe_env" class="anchor"></a><code>exe_env : <a href="../InferModules/Exe_env/index.html#type-t">InferModules.Exe_env.t</a>;</code></td></tr></table><code>}</code><code></code></div><div class="doc"></div></div><div class="spec type" id="type-cluster_callback_t"><a href="#type-cluster_callback_t" class="anchor"></a><div class="def type"><code><span class="keyword">type </span>cluster_callback_t</code><code><span class="keyword"> = </span><a href="index.html#type-cluster_callback_args">cluster_callback_args</a> <span class="keyword">&#8209;&gt;</span> unit</code><code></code></div><div class="doc"></div></div><div class="spec val" id="val-register_procedure_callback"><a href="#val-register_procedure_callback" class="anchor"></a><div class="def val"><code><span class="keyword">val </span>register_procedure_callback : ?&#8288;dynamic_dispatch:bool <span class="keyword">&#8209;&gt;</span> <a href="../../InferBase/InferBase/Language/index.html#type-t">InferBase.Language.t</a> <span class="keyword">&#8209;&gt;</span> <a href="index.html#type-proc_callback_t">proc_callback_t</a> <span class="keyword">&#8209;&gt;</span> unit</code></div><div class="doc"><p>register a procedure callback</p></div></div><div class="spec val" id="val-register_cluster_callback"><a href="#val-register_cluster_callback" class="anchor"></a><div class="def val"><code><span class="keyword">val </span>register_cluster_callback : <a href="../../InferBase/InferBase/Language/index.html#type-t">InferBase.Language.t</a> <span class="keyword">&#8209;&gt;</span> <a href="index.html#type-cluster_callback_t">cluster_callback_t</a> <span class="keyword">&#8209;&gt;</span> unit</code></div><div class="doc"><p>register a cluster callback</p></div></div><div class="spec val" id="val-iterate_callbacks"><a href="#val-iterate_callbacks" class="anchor"></a><div class="def val"><code><span class="keyword">val </span>iterate_callbacks : <a href="../InferModules/Exe_env/index.html#type-t">InferModules.Exe_env.t</a> <span class="keyword">&#8209;&gt;</span> unit</code></div><div class="doc"><p>Invoke all the registered callbacks.</p></div></div></body></html>