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.

2 lines
9.4 KiB

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml"><head><title>IR__Annot (infer.IR__Annot)</title><link rel="stylesheet" href="../../odoc.css"/><meta charset="utf-8"/><meta name="generator" content="odoc 1.5.1"/><meta name="viewport" content="width=device-width,initial-scale=1.0"/><script src="../../highlight.pack.js"></script><script>hljs.initHighlightingOnLoad();</script></head><body><div class="content"><header><nav><a href="../index.html">Up</a> <a href="../index.html">infer</a> &#x00BB; IR__Annot</nav><h1>Module <code>IR__Annot</code></h1><p>The Smallfoot Intermediate Language: Annotations</p></header><div class="spec module" id="module-F"><a href="#module-F" class="anchor"></a><code><span class="keyword">module</span> F = Stdlib.Format</code></div><dl><dt class="spec type" id="type-t"><a href="#type-t" class="anchor"></a><code><span class="keyword">type</span> t</code><code> = </code><code>{</code><table class="record"><tr id="type-t.class_name" class="anchored"><td class="def field"><a href="#type-t.class_name" class="anchor"></a><code>class_name : string;</code></td><td class="doc"><p>name of the annotation</p></td></tr><tr id="type-t.parameters" class="anchored"><td class="def field"><a href="#type-t.parameters" class="anchor"></a><code>parameters : <span><a href="index.html#type-parameter">parameter</a> list</span>;</code></td></tr></table><code>}</code></dt><dd><p>Type to represent an <code>@Annotation</code> with potentially complex parameter values such as arrays or other annotations.</p></dd></dl><dl><dt class="spec type" id="type-parameter"><a href="#type-parameter" class="anchor"></a><code><span class="keyword">and</span> parameter</code><code> = </code><code>{</code><table class="record"><tr id="type-parameter.name" class="anchored"><td class="def field"><a href="#type-parameter.name" class="anchor"></a><code>name : <span>string option</span>;</code></td></tr><tr id="type-parameter.value" class="anchored"><td class="def field"><a href="#type-parameter.value" class="anchor"></a><code>value : <a href="index.html#type-value">value</a>;</code></td></tr></table><code>}</code></dt><dt class="spec type" id="type-value"><a href="#type-value" class="anchor"></a><code><span class="keyword">and</span> value</code><code> = </code><table class="variant"><tr id="type-value.Str" class="anchored"><td class="def constructor"><a href="#type-value.Str" class="anchor"></a><code>| </code><code><span class="constructor">Str</span> <span class="keyword">of</span> string</code></td></tr><tr id="type-value.Bool" class="anchored"><td class="def constructor"><a href="#type-value.Bool" class="anchor"></a><code>| </code><code><span class="constructor">Bool</span> <span class="keyword">of</span> bool</code></td></tr><tr id="type-value.Enum" class="anchored"><td class="def constructor"><a href="#type-value.Enum" class="anchor"></a><code>| </code><code><span class="constructor">Enum</span> <span class="keyword">of</span> </code><code>{</code><table class="record"><tr id="type-value.class_typ" class="anchored"><td class="def field"><a href="#type-value.class_typ" class="anchor"></a><code>class_typ : <a href="../IR/Typ/index.html#type-t">IR.Typ.t</a>;</code></td></tr><tr id="type-value.value" class="anchored"><td class="def field"><a href="#type-value.value" class="anchor"></a><code>value : string;</code></td></tr></table><code>}</code></td></tr><tr id="type-value.Array" class="anchored"><td class="def constructor"><a href="#type-value.Array" class="anchor"></a><code>| </code><code><span class="constructor">Array</span> <span class="keyword">of</span> <span><a href="index.html#type-value">value</a> list</span></code></td></tr><tr id="type-value.Class" class="anchored"><td class="def constructor"><a href="#type-value.Class" class="anchor"></a><code>| </code><code><span class="constructor">Class</span> <span class="keyword">of</span> <a href="../IR/Typ/index.html#type-t">IR.Typ.t</a></code></td></tr><tr id="type-value.Annot" class="anchored"><td class="def constructor"><a href="#type-value.Annot" class="anchor"></a><code>| </code><code><span class="constructor">Annot</span> <span class="keyword">of</span> <a href="index.html#type-t">t</a></code></td></tr></table></dt><dd><p>Type to represent possible annotation parameter values. Note that support for numeric parameters is missing for now due to an issue with <code>MaximumSharing</code> and <code>int64</code>.</p></dd></dl><div><div class="spec include"><div class="doc"><dl><dt class="spec value" id="val-compare"><a href="#val-compare" class="anchor"></a><code><span class="keyword">val</span> compare : <a href="index.html#type-t">t</a> <span>&#45;&gt;</span> <a href="index.html#type-t">t</a> <span>&#45;&gt;</span> int</code></dt><dt class="spec value" id="val-compare_parameter"><a href="#val-compare_parameter" class="anchor"></a><code><span class="keyword">val</span> compare_parameter : <a href="index.html#type-parameter">parameter</a> <span>&#45;&gt;</span> <a href="index.html#type-parameter">parameter</a> <span>&#45;&gt;</span> int</code></dt><dt class="spec value" id="val-compare_value"><a href="#val-compare_value" class="anchor"></a><code><span class="keyword">val</span> compare_value : <a href="index.html#type-value">value</a> <span>&#45;&gt;</span> <a href="index.html#type-value">value</a> <span>&#45;&gt;</span> int</code></dt><dt class="spec value" id="val-equal"><a href="#val-equal" class="anchor"></a><code><span class="keyword">val</span> equal : <a href="index.html#type-t">t</a> <span>&#45;&gt;</span> <a href="index.html#type-t">t</a> <span>&#45;&gt;</span> bool</code></dt><dt class="spec value" id="val-equal_parameter"><a href="#val-equal_parameter" class="anchor"></a><code><span class="keyword">val</span> equal_parameter : <a href="index.html#type-parameter">parameter</a> <span>&#45;&gt;</span> <a href="index.html#type-parameter">parameter</a> <span>&#45;&gt;</span> bool</code></dt><dt class="spec value" id="val-equal_value"><a href="#val-equal_value" class="anchor"></a><code><span class="keyword">val</span> equal_value : <a href="index.html#type-value">value</a> <span>&#45;&gt;</span> <a href="index.html#type-value">value</a> <span>&#45;&gt;</span> bool</code></dt><dt class="spec value" id="val-compare"><a href="#val-compare" class="anchor"></a><code><span class="keyword">val</span> compare : <a href="index.html#type-t">t</a> <span>&#45;&gt;</span> <a href="index.html#type-t">t</a> <span>&#45;&gt;</span> int</code></dt><dt class="spec value" id="val-compare_parameter"><a href="#val-compare_parameter" class="anchor"></a><code><span class="keyword">val</span> compare_parameter : <a href="index.html#type-parameter">parameter</a> <span>&#45;&gt;</span> <a href="index.html#type-parameter">parameter</a> <span>&#45;&gt;</span> int</code></dt><dt class="spec value" id="val-compare_value"><a href="#val-compare_value" class="anchor"></a><code><span class="keyword">val</span> compare_value : <a href="index.html#type-value">value</a> <span>&#45;&gt;</span> <a href="index.html#type-value">value</a> <span>&#45;&gt;</span> int</code></dt></dl></div></div></div><dl><dt class="spec value" id="val-volatile"><a href="#val-volatile" class="anchor"></a><code><span class="keyword">val</span> volatile : <a href="index.html#type-t">t</a></code></dt><dd><p>annotation for fields marked with the &quot;volatile&quot; keyword</p></dd></dl><dl><dt class="spec value" id="val-final"><a href="#val-final" class="anchor"></a><code><span class="keyword">val</span> final : <a href="index.html#type-t">t</a></code></dt><dd><p>annotation for fields marked with the &quot;final&quot; keyword</p></dd></dl><dl><dt class="spec value" id="val-has_matching_str_value"><a href="#val-has_matching_str_value" class="anchor"></a><code><span class="keyword">val</span> has_matching_str_value : <span>pred:<span>(string <span>&#45;&gt;</span> bool)</span></span> <span>&#45;&gt;</span> <a href="index.html#type-value">value</a> <span>&#45;&gt;</span> bool</code></dt><dd><p>Check if annotation parameter value contains a string satisfying a predicate. For convenience it works both with raw <code>Str</code> and <code>Str</code> inside <code>Array</code>.</p></dd></dl><dl><dt class="spec value" id="val-find_parameter"><a href="#val-find_parameter" class="anchor"></a><code><span class="keyword">val</span> find_parameter : <a href="index.html#type-t">t</a> <span>&#45;&gt;</span> <span>name:string</span> <span>&#45;&gt;</span> <span><a href="index.html#type-value">value</a> option</span></code></dt><dt class="spec value" id="val-pp"><a href="#val-pp" class="anchor"></a><code><span class="keyword">val</span> pp : <a href="index.html#module-F">F</a>.formatter <span>&#45;&gt;</span> <a href="index.html#type-t">t</a> <span>&#45;&gt;</span> unit</code></dt><dd><p>Pretty print an annotation.</p></dd></dl><div class="spec module" id="module-Item"><a href="#module-Item" class="anchor"></a><code><span class="keyword">module</span> <a href="Item/index.html">Item</a> : <span class="keyword">sig</span> ... <span class="keyword">end</span></code></div><div class="spec module" id="module-Class"><a href="#module-Class" class="anchor"></a><code><span class="keyword">module</span> <a href="Class/index.html">Class</a> : <span class="keyword">sig</span> ... <span class="keyword">end</span></code></div><div class="spec module" id="module-Method"><a href="#module-Method" class="anchor"></a><code><span class="keyword">module</span> <a href="Method/index.html">Method</a> : <span class="keyword">sig</span> ... <span class="keyword">end</span></code></div></div></body></html>