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.

7 lines
4.0 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>Nullsafe__InferredNullability (infer.Nullsafe__InferredNullability)</title><link rel="stylesheet" href="../../odoc.css"/><meta charset="utf-8"/><meta name="generator" content="odoc 1.5.0"/><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; Nullsafe__InferredNullability</nav><h1>Module <code>Nullsafe__InferredNullability</code></h1></header><aside><p>Module to represent nullability of expressions inferred during flow-sensitive symbolic execution. NOTE: This is complementaty to <span class="xref-unresolved" title="unresolved reference to &quot;InferredNullability.t&quot;"><code>InferredNullability</code>.t</span>. <code>InferredNullability</code> contains info about _formal_ nullability (what does the code say about nullability of a given type, according to explicit annotations and implicit agreements (e.g. models)). In contrast, InferredNullability represents what Nullsafe thinks about such and such expression according to its type inference rules.</p></aside><dl><dt class="spec type" id="type-t"><a href="#type-t" class="anchor"></a><code><span class="keyword">type</span> t</code></dt></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></dl></div></div></div><dl><dt class="spec value" id="val-get_nullability"><a href="#val-get_nullability" class="anchor"></a><code><span class="keyword">val</span> get_nullability : <a href="index.html#type-t">t</a> <span>&#45;&gt;</span> <a href="../Nullsafe/Nullability/index.html#type-t">Nullsafe.Nullability.t</a></code></dt><dt class="spec value" id="val-create"><a href="#val-create" class="anchor"></a><code><span class="keyword">val</span> create : <a href="../Nullsafe/TypeOrigin/index.html#type-t">Nullsafe.TypeOrigin.t</a> <span>&#45;&gt;</span> <a href="index.html#type-t">t</a></code></dt><dt class="spec value" id="val-is_nonnullish"><a href="#val-is_nonnullish" class="anchor"></a><code><span class="keyword">val</span> is_nonnullish : <a href="index.html#type-t">t</a> <span>&#45;&gt;</span> bool</code></dt><dd><p>Check whether corresponding <code>Nullability</code> is <code>Nullability.is_nonnullish</code></p></dd></dl><dl><dt class="spec value" id="val-get_origin"><a href="#val-get_origin" class="anchor"></a><code><span class="keyword">val</span> get_origin : <a href="index.html#type-t">t</a> <span>&#45;&gt;</span> <a href="../Nullsafe/TypeOrigin/index.html#type-t">Nullsafe.TypeOrigin.t</a></code></dt><dd><p>The simple explanation of how was nullability inferred.</p></dd></dl><dl><dt class="spec value" id="val-join"><a href="#val-join" class="anchor"></a><code><span class="keyword">val</span> join : <a href="index.html#type-t">t</a> <span>&#45;&gt;</span> <a href="index.html#type-t">t</a> <span>&#45;&gt;</span> <a href="index.html#type-t">t</a></code></dt><dd><p>This is what happens with nullability when we join two flows in CFG, e.g.</p><pre><code class="ml">if(something) {
a = e1;
} else {
a = e2;
}
// what is nullability of `a` at this point?</code></pre></dd></dl><dl><dt class="spec value" id="val-origin_is_fun_defined"><a href="#val-origin_is_fun_defined" class="anchor"></a><code><span class="keyword">val</span> origin_is_fun_defined : <a href="index.html#type-t">t</a> <span>&#45;&gt;</span> bool</code></dt><dt class="spec value" id="val-pp"><a href="#val-pp" class="anchor"></a><code><span class="keyword">val</span> pp : Stdlib.Format.formatter <span>&#45;&gt;</span> <a href="index.html#type-t">t</a> <span>&#45;&gt;</span> unit</code></dt></dl></div></body></html>