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>
<htmlxmlns="http://www.w3.org/1999/xhtml"><head><title>IR__Tenv (infer.IR__Tenv)</title><linkrel="stylesheet"href="../../odoc.css"/><metacharset="utf-8"/><metaname="generator"content="odoc 1.5.1"/><metaname="viewport"content="width=device-width,initial-scale=1.0"/><scriptsrc="../../highlight.pack.js"></script><script>hljs.initHighlightingOnLoad();</script></head><body><divclass="content"><header><nav><ahref="../index.html">Up</a>–<ahref="../index.html">infer</a>» IR__Tenv</nav><h1>Module <code>IR__Tenv</code></h1></header><aside><p>Module for Type Environments.</p></aside><dl><dtclass="spec type"id="type-t"><ahref="#type-t"class="anchor"></a><code><spanclass="keyword">type</span> t</code></dt><dd><p>Type for type environment.</p></dd></dl><dl><dtclass="spec value"id="val-create"><ahref="#val-create"class="anchor"></a><code><spanclass="keyword">val</span> create : unit <span>-></span><ahref="index.html#type-t">t</a></code></dt><dd><p>Create a new type environment.</p></dd></dl><dl><dtclass="spec value"id="val-load"><ahref="#val-load"class="anchor"></a><code><spanclass="keyword">val</span> load : <ahref="../IBase/SourceFile/index.html#type-t">IBase.SourceFile.t</a><span>-></span><span><ahref="index.html#type-t">t</a> option</span></code></dt><dd><p>Load a type environment for a source file</p></dd></dl><dl><dtclass="spec value"id="val-store_debug_file_for_source"><ahref="#val-store_debug_file_for_source"class="anchor"></a><code><spanclass="keyword">val</span> store_debug_file_for_source : <ahref="../IBase/SourceFile/index.html#type-t">IBase.SourceFile.t</a><span>-></span><ahref="index.html#type-t">t</a><span>-></span> unit</code></dt><dtclass="spec value"id="val-read"><ahref="#val-read"class="anchor"></a><code><spanclass="keyword">val</span> read : <ahref="../IBase/DB/index.html#type-filename">IBase.DB.filename</a><span>-></span><span><ahref="index.html#type-t">t</a> option</span></code></dt><dd><p>read and return a type environment from the given file</p></dd></dl><dl><dtclass="spec value"id="val-load_global"><ahref="#val-load_global"class="anchor"></a><code><spanclass="keyword">val</span> load_global : unit <span>-></span><span><ahref="index.html#type-t">t</a> option</span></code></dt><dd><p>load the global type environment (Java)</p></dd></dl><dl><dtclass="spec value"id="val-store_global"><ahref="#val-store_global"class="anchor"></a><code><spanclass="keyword">val</span> store_global : <ahref="index.html#type-t">t</a><span>-></span> unit</code></dt><dd><p>save a global type environment (Java)</p></dd></dl><dl><dtclass="spec value"id="val-lookup"><ahref="#val-lookup"class="anchor"></a><code><spanclass="keyword">val</span> lookup : <ahref="index.html#type-t">t</a><span>-></span><ahref="../IR/Typ/Name/index.html#type-t">IR.Typ.Name.t</a><span>-></span><span><ahref="../IR/Struct/index.html#type-t">IR.Struct.t</a> option</span></code></dt><dd><p>Look up a name in the global type environment.</p></dd></dl><dl><dtclass="spec value"id="val-mk_struct"><ahref="#val-mk_struct"class="anchor"></a><code><spanclass="keyword">val</span> mk_struct : <ahref="index.html#type-t">t</a><span>-></span><span>?⁠default:<ahref="../IR/Struct/index.html#type-t">IR.Struct.t</a></span><span>-></span><span>?⁠fields:<ahref="../IR/Struct/index.html#type-fields">IR.Struct.fields</a></span><span>-></span><span>?⁠statics:<ahref="../IR/Struct/index.html#type-fields">IR.Struct.fields</a></span><span>-></span><span>?⁠methods:<span><ahref="../IR/Procname/index.html#type-t">IR.Procname.t</a> list</span></span><span>-></span><span>?⁠exported_objc_methods:<span><ahref="../IR/Procname/index.html#type-t">IR.Procname.t</a> list</span></span><span>-></span><span>?⁠supers:<span><ahref="../IR/Typ/Name/index.html#type-t">IR.Typ.Name.t</a> list</span></span><span>-></span><span>?⁠objc_protocols:<span><ahref="../IR/Typ/Name/index.html#type-t">IR.Typ.Name.t</a> list</span></span><span>-></span><span>?⁠annots:<ahref="../IR/Annot/Item/index.html#type-t">IR.Annot.Item.t</a></span><span>-></span><span>?⁠java_class_info:<ahref="../IR/Struct/index.html#type-java_class_info">IR.Struct.java_class_info</a></span><span>-></span><span>?⁠dummy:bool</span><span>-></span><ahref="../IR/Typ/Name/index.html#type-t">IR.Typ.Name.t</a><span>-></span><ahref="../IR/Struct/index.html#type-t">IR.Struct.t</a></code></dt><dd><p>Construct a struct_typ, normalizing field types</p></dd></dl><dl><dtclass="spec value"id="val-add_field"><ahref="#val-add_field"class="anchor"></a><code><spanclass="keyword">val</span> add_field : <ahref="index.html#type-t">t</a><span>-></span><ahref="../IR/Typ/Name/index.html#type-t">IR.Typ.Name.t</a><span>-></span><ahref="../IR/Struct/index.html#type-field">IR.Struct.field</a><span>-></span> unit</code></dt><dd><p>Add a field to a given struct in the global type environment.</p></dd></dl><dl><dtclass="spec value"id="val-pp"><ahref="#val-pp"class="anchor"></a><code><spanclass="keyword">val</span> pp : Stdlib.Format.formatter <span>-></span><ahref="index.html#type-t">t</a><span>-></span> unit</code></dt><dd><p>print a type environment</p></dd></dl><dl><dtclass="spec value"id="val-implements_remodel_class"><ahref="#val-implements_remodel_class"class="anchor"></a><code><spanclass="keyword">val</span> implements_remodel_class : <ahref="index.html#type-t">t</a><span>-></span><ahref="../IR/Typ/Name/index.html#type-t">IR.Typ.Name.t</a><span>-></span> bool</code></dt><dd><p>Check if a class implements the Remodel class</p></dd></dl><dl><dtclass="spec type"id="type-per_file"><ahref="#type-per_file"class="anchor"></a><code><spanclass="keyword">type</span> per_file</code><code> = </code><tableclass="variant"><trid="type-per_file.Global"class="anchored"><tdclass="def constructor"><ahref="#type-per_file.Global"class="anchor"></a><code>| </code><code><spanclass="constructor">Global</span></code></td></tr><trid="type-per_file.FileLocal"class="anchored"><tdclass="def constructor"><ahref="#type-per_file.FileLocal"class="anchor"></a><code>| </code><code><spanclass="constructor">FileLocal</span><spanclass="keyword">of</span><ahref="index.html#type-t">t</a></code></td></tr></table></dt></dl><dl><dtclass="spec value"id="val-pp_per_file"><ahref="#val-pp_per_file"class="anchor"></a><code><spanclass="keyword">val</span> pp_per_file : Stdlib.Format.formatter <span>-></span><ahref="index.html#type-per_file">per_file</a><span>-></span> unit</code></dt><dd><p>print per file type environment</p></dd></dl><dl><dtclass="spec value"id="val-merge"><ahref="#val-merge"class="anchor"></a><code><spanclass="keyword">val</span> merge : <span>src:<ahref="index.html#type-t">t</a></span><span>-></span><span>dst:<ahref="index.html#type-t">t</a></span><span>-></span> unit</code></dt><dd><p>Merge <code>src</code> into <code>dst</code> possibly overwriting pre existing procs in <code>dst</code>.</p></dd></dl><dl><dtclass="spec value"id="val-merge_per_file"><ahref="#val-merge_per_file"class="anchor"></a><code><spanclass="keyword">val</span> merge_per_file : <span>src:<ahref="index.html#type-per_file">per_file</a></span><span>-></span><span>dst:<ahref="index.html#type-per_file">per_file</a></span><span>-></span><ahref="index.html#type-per_file">per_file</a></code></dt><dd><p>Best-effort merge of <code>src</code> into <code>dst</code>. If a procedure is both in <code>dst</code> and <code>src</code>, the one in <code>dst</code> will get overwritten.</p></dd></dl><dl><dtclass="spec value"id="val-resolve_method"><ahref="#val-resolve_method"class="anchor"></a><code><spanclass="keyword">val</span> resolve_method : <span>method_exists:<span>(<ahref="../IR/Procname/index.html#type-t">IR.Procname.t</a><span>-></span><span><ahref="../IR/Procname/index.html#type-t">IR.Procname.t</a> list</span><span>-></span> bool)</span></span><span>-></span><ahref="index.html#type-t">t</a><span>-></span><ahref="../IR/Typ/Name/index.html#type-t">IR.Typ.Name.t</a><span>-></span><ahref="../IR/Procname/index.html#type-t">IR.Procname.t</a><span>-></span><span><ahref="../IR/Procname/index.html#type-t">IR.Procname.t</a> option</span></code></dt><dd><p><code>resolve_method ~method_exists tenv class_name procname</code> tries to resolve <code>procname</code> to a method in <code>class_name</code> or its super-classes, that is non-virtual (non-Java-interface method). <code>method_exists adapted_procname methods</code> should check if <code>adapted_procname</code> (<code>procname</code> but with its class potentially changed to some <code>other_class</code>) is among the <code>methods</code> of <code>other_class</code>.</p></dd></dl><divclass="spec module"id="module-SQLite"><ahref="#module-SQLite"class="anchor"></a><code><spanclass="keyword">module</span><ahref="SQLite/index.html">SQLite</a> : <ahref="../IBase/SqliteUtils/index.html#module-type-Data">IBase.SqliteUtils.Data</a><spanclass="keyword">with</span><spanclass="keyword">type</span><ahref="../IBase/SqliteUtils/module-type-Data/index.html#type-t">t</a> = <ahref="index.html#type-per_file">per_file</a></code></div></div></body></html>