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.
6 lines
11 KiB
6 lines
11 KiB
<!DOCTYPE html>
|
|
<html xmlns="http://www.w3.org/1999/xhtml"><head><title>Propset (infer.InferModules.Propset)</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> — <span class="package">package <a href="../../index.html">infer</a></span></nav><header><h1><span class="keyword">Module</span> <span class="module-path">InferModules.Propset</span></h1></header><p>Functions for Sets of Propositions with and without sharing</p><h3>Sets of Propositions</h3><div class="spec type" id="type-t"><a href="#type-t" class="anchor"></a><div class="def type"><code><span class="keyword">type </span>t</code><code></code><code></code></div><div class="doc"><p>Sets of propositions.
|
|
The invariant is maintaned that Prop.prop_rename_primed_footprint_vars is called on any prop added to the set.</p></div></div><div class="spec val" id="val-compare"><a href="#val-compare" class="anchor"></a><div class="def val"><code><span class="keyword">val </span>compare : <a href="index.html#type-t">t</a> <span class="keyword">‑></span> <a href="index.html#type-t">t</a> <span class="keyword">‑></span> int</code></div><div class="doc"><p>Compare propsets</p></div></div><div class="spec val" id="val-singleton"><a href="#val-singleton" class="anchor"></a><div class="def val"><code><span class="keyword">val </span>singleton : <a href="../../../InferIR/InferIR/Tenv/index.html#type-t">InferIR.Tenv.t</a> <span class="keyword">‑></span> <a href="../Prop/index.html#type-normal">Prop.normal</a> <a href="../Prop/index.html#type-t">Prop.t</a> <span class="keyword">‑></span> <a href="index.html#type-t">t</a></code></div><div class="doc"><p>Singleton set.</p></div></div><div class="spec val" id="val-mem"><a href="#val-mem" class="anchor"></a><div class="def val"><code><span class="keyword">val </span>mem : <a href="../Prop/index.html#type-normal">Prop.normal</a> <a href="../Prop/index.html#type-t">Prop.t</a> <span class="keyword">‑></span> <a href="index.html#type-t">t</a> <span class="keyword">‑></span> bool</code></div><div class="doc"><p>Set membership.</p></div></div><div class="spec val" id="val-union"><a href="#val-union" class="anchor"></a><div class="def val"><code><span class="keyword">val </span>union : <a href="index.html#type-t">t</a> <span class="keyword">‑></span> <a href="index.html#type-t">t</a> <span class="keyword">‑></span> <a href="index.html#type-t">t</a></code></div><div class="doc"><p>Set union.</p></div></div><div class="spec val" id="val-inter"><a href="#val-inter" class="anchor"></a><div class="def val"><code><span class="keyword">val </span>inter : <a href="index.html#type-t">t</a> <span class="keyword">‑></span> <a href="index.html#type-t">t</a> <span class="keyword">‑></span> <a href="index.html#type-t">t</a></code></div><div class="doc"><p>Set intersection</p></div></div><div class="spec val" id="val-add"><a href="#val-add" class="anchor"></a><div class="def val"><code><span class="keyword">val </span>add : <a href="../../../InferIR/InferIR/Tenv/index.html#type-t">InferIR.Tenv.t</a> <span class="keyword">‑></span> <a href="../Prop/index.html#type-normal">Prop.normal</a> <a href="../Prop/index.html#type-t">Prop.t</a> <span class="keyword">‑></span> <a href="index.html#type-t">t</a> <span class="keyword">‑></span> <a href="index.html#type-t">t</a></code></div><div class="doc"><p>Add <code class="code">prop</code> to propset.</p></div></div><div class="spec val" id="val-diff"><a href="#val-diff" class="anchor"></a><div class="def val"><code><span class="keyword">val </span>diff : <a href="index.html#type-t">t</a> <span class="keyword">‑></span> <a href="index.html#type-t">t</a> <span class="keyword">‑></span> <a href="index.html#type-t">t</a></code></div><div class="doc"><p>Set difference.</p></div></div><div class="spec val" id="val-empty"><a href="#val-empty" class="anchor"></a><div class="def val"><code><span class="keyword">val </span>empty : <a href="index.html#type-t">t</a></code></div><div class="doc"><p>The empty set of propositions.</p></div></div><div class="spec val" id="val-size"><a href="#val-size" class="anchor"></a><div class="def val"><code><span class="keyword">val </span>size : <a href="index.html#type-t">t</a> <span class="keyword">‑></span> int</code></div><div class="doc"><p>Size of the set</p></div></div><div class="spec val" id="val-from_proplist"><a href="#val-from_proplist" class="anchor"></a><div class="def val"><code><span class="keyword">val </span>from_proplist : <a href="../../../InferIR/InferIR/Tenv/index.html#type-t">InferIR.Tenv.t</a> <span class="keyword">‑></span> <a href="../Prop/index.html#type-normal">Prop.normal</a> <a href="../Prop/index.html#type-t">Prop.t</a> list <span class="keyword">‑></span> <a href="index.html#type-t">t</a></code></div><div class="doc"></div></div><div class="spec val" id="val-to_proplist"><a href="#val-to_proplist" class="anchor"></a><div class="def val"><code><span class="keyword">val </span>to_proplist : <a href="index.html#type-t">t</a> <span class="keyword">‑></span> <a href="../Prop/index.html#type-normal">Prop.normal</a> <a href="../Prop/index.html#type-t">Prop.t</a> list</code></div><div class="doc"></div></div><div class="spec val" id="val-map"><a href="#val-map" class="anchor"></a><div class="def val"><code><span class="keyword">val </span>map : <a href="../../../InferIR/InferIR/Tenv/index.html#type-t">InferIR.Tenv.t</a> <span class="keyword">‑></span> (<a href="../Prop/index.html#type-normal">Prop.normal</a> <a href="../Prop/index.html#type-t">Prop.t</a> <span class="keyword">‑></span> <a href="../Prop/index.html#type-normal">Prop.normal</a> <a href="../Prop/index.html#type-t">Prop.t</a>) <span class="keyword">‑></span> <a href="index.html#type-t">t</a> <span class="keyword">‑></span> <a href="index.html#type-t">t</a></code></div><div class="doc"><p>Apply function to all the elements of the propset.</p></div></div><div class="spec val" id="val-map_option"><a href="#val-map_option" class="anchor"></a><div class="def val"><code><span class="keyword">val </span>map_option : <a href="../../../InferIR/InferIR/Tenv/index.html#type-t">InferIR.Tenv.t</a> <span class="keyword">‑></span> (<a href="../Prop/index.html#type-normal">Prop.normal</a> <a href="../Prop/index.html#type-t">Prop.t</a> <span class="keyword">‑></span> <a href="../Prop/index.html#type-normal">Prop.normal</a> <a href="../Prop/index.html#type-t">Prop.t</a> option) <span class="keyword">‑></span> <a href="index.html#type-t">t</a> <span class="keyword">‑></span> <a href="index.html#type-t">t</a></code></div><div class="doc"><p>Apply function to all the elements of the propset, removing those where it returns <code class="code">None</code>.</p></div></div><div class="spec val" id="val-fold"><a href="#val-fold" class="anchor"></a><div class="def val"><code><span class="keyword">val </span>fold : (<span class="type-var">'a</span> <span class="keyword">‑></span> <a href="../Prop/index.html#type-normal">Prop.normal</a> <a href="../Prop/index.html#type-t">Prop.t</a> <span class="keyword">‑></span> <span class="type-var">'a</span>) <span class="keyword">‑></span> <span class="type-var">'a</span> <span class="keyword">‑></span> <a href="index.html#type-t">t</a> <span class="keyword">‑></span> <span class="type-var">'a</span></code></div><div class="doc"><p><code class="code">fold f pset a</code> computes <code class="code">(f pN ... (f p2 (f p1 a))...)</code>,
|
|
where <code class="code">p1 ... pN</code> are the elements of pset, in increasing
|
|
order.</p></div></div><div class="spec val" id="val-iter"><a href="#val-iter" class="anchor"></a><div class="def val"><code><span class="keyword">val </span>iter : (<a href="../Prop/index.html#type-normal">Prop.normal</a> <a href="../Prop/index.html#type-t">Prop.t</a> <span class="keyword">‑></span> unit) <span class="keyword">‑></span> <a href="index.html#type-t">t</a> <span class="keyword">‑></span> unit</code></div><div class="doc"><p><code class="code">iter f pset</code> computes (f p1;f p2;..;f pN)
|
|
where <code class="code">p1 ... pN</code> are the elements of pset, in increasing order.</p></div></div><div class="spec val" id="val-partition"><a href="#val-partition" class="anchor"></a><div class="def val"><code><span class="keyword">val </span>partition : (<a href="../Prop/index.html#type-normal">Prop.normal</a> <a href="../Prop/index.html#type-t">Prop.t</a> <span class="keyword">‑></span> bool) <span class="keyword">‑></span> <a href="index.html#type-t">t</a> <span class="keyword">‑></span> <a href="index.html#type-t">t</a><span class="keyword"> * </span><a href="index.html#type-t">t</a></code></div><div class="doc"></div></div><div class="spec val" id="val-subseteq"><a href="#val-subseteq" class="anchor"></a><div class="def val"><code><span class="keyword">val </span>subseteq : <a href="index.html#type-t">t</a> <span class="keyword">‑></span> <a href="index.html#type-t">t</a> <span class="keyword">‑></span> bool</code></div><div class="doc"></div></div><div class="spec val" id="val-is_empty"><a href="#val-is_empty" class="anchor"></a><div class="def val"><code><span class="keyword">val </span>is_empty : <a href="index.html#type-t">t</a> <span class="keyword">‑></span> bool</code></div><div class="doc"><p>Set emptiness check.</p></div></div><div class="spec val" id="val-filter"><a href="#val-filter" class="anchor"></a><div class="def val"><code><span class="keyword">val </span>filter : (<a href="../Prop/index.html#type-normal">Prop.normal</a> <a href="../Prop/index.html#type-t">Prop.t</a> <span class="keyword">‑></span> bool) <span class="keyword">‑></span> <a href="index.html#type-t">t</a> <span class="keyword">‑></span> <a href="index.html#type-t">t</a></code></div><div class="doc"></div></div><h3>Pretty print</h3><div class="spec val" id="val-d"><a href="#val-d" class="anchor"></a><div class="def val"><code><span class="keyword">val </span>d : <a href="../Prop/index.html#type-normal">Prop.normal</a> <a href="../Prop/index.html#type-t">Prop.t</a> <span class="keyword">‑></span> <a href="index.html#type-t">t</a> <span class="keyword">‑></span> unit</code></div><div class="doc"><p>dump a propset coming form the given initial prop</p></div></div></body></html> |