linol/ocaml/Shape_reduce/index.html
2025-08-24 01:27:17 +00:00

2 lines
5.4 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml"><head><title>Shape_reduce (ocaml.Shape_reduce)</title><meta charset="utf-8"/><link rel="stylesheet" href="../../_odoc-theme/odoc.css"/><meta name="generator" content="odoc 3.1.0"/><meta name="viewport" content="width=device-width,initial-scale=1.0"/><script src="../../highlight.pack.js"></script><script>hljs.initHighlightingOnLoad();</script></head><body class="odoc"><nav class="odoc-nav"><a href="../index.html">Up</a> <a href="../../index.html">Index</a> &#x00BB; <a href="../index.html">ocaml</a> &#x00BB; Shape_reduce</nav><header class="odoc-preamble"><h1>Module <code><span>Shape_reduce</span></code></h1></header><div class="odoc-content"><div class="odoc-spec"><div class="spec type anchored" id="type-result"><a href="#type-result" class="anchor"></a><code><span><span class="keyword">type</span> result</span><span> = </span></code><ol><li id="type-result.Resolved" class="def variant constructor anchored"><a href="#type-result.Resolved" class="anchor"></a><code><span>| </span><span><span class="constructor">Resolved</span> <span class="keyword">of</span> <a href="../Shape/Uid/index.html#type-t">Shape.Uid.t</a></span></code><div class="def-doc"><span class="comment-delim">(*</span><p>Shape reduction succeeded and a uid was found</p><span class="comment-delim">*)</span></div></li><li id="type-result.Resolved_alias" class="def variant constructor anchored"><a href="#type-result.Resolved_alias" class="anchor"></a><code><span>| </span><span><span class="constructor">Resolved_alias</span> <span class="keyword">of</span> <a href="../Shape/Uid/index.html#type-t">Shape.Uid.t</a> * <a href="#type-result">result</a></span></code><div class="def-doc"><span class="comment-delim">(*</span><p>Reduction led to an alias</p><span class="comment-delim">*)</span></div></li><li id="type-result.Unresolved" class="def variant constructor anchored"><a href="#type-result.Unresolved" class="anchor"></a><code><span>| </span><span><span class="constructor">Unresolved</span> <span class="keyword">of</span> <a href="../Shape/index.html#type-t">Shape.t</a></span></code><div class="def-doc"><span class="comment-delim">(*</span><p>Result still contains <code>Comp_unit</code> terms</p><span class="comment-delim">*)</span></div></li><li id="type-result.Approximated" class="def variant constructor anchored"><a href="#type-result.Approximated" class="anchor"></a><code><span>| </span><span><span class="constructor">Approximated</span> <span class="keyword">of</span> <span><a href="../Shape/Uid/index.html#type-t">Shape.Uid.t</a> option</span></span></code><div class="def-doc"><span class="comment-delim">(*</span><p>Reduction failed: it can arrive with first-class modules for example</p><span class="comment-delim">*)</span></div></li><li id="type-result.Internal_error_missing_uid" class="def variant constructor anchored"><a href="#type-result.Internal_error_missing_uid" class="anchor"></a><code><span>| </span><span><span class="constructor">Internal_error_missing_uid</span></span></code><div class="def-doc"><span class="comment-delim">(*</span><p>Reduction succeeded but no uid was found, this should never happen</p><span class="comment-delim">*)</span></div></li></ol></div><div class="spec-doc"><p>The result of reducing a shape and looking for its uid</p></div></div><div class="odoc-spec"><div class="spec value anchored" id="val-print_result"><a href="#val-print_result" class="anchor"></a><code><span><span class="keyword">val</span> print_result : <span><a href="../Stdlib/Format/index.html#type-formatter">Stdlib.Format.formatter</a> <span class="arrow">&#45;&gt;</span></span> <span><a href="#type-result">result</a> <span class="arrow">&#45;&gt;</span></span> unit</span></code></div></div><div class="odoc-spec"><div class="spec module anchored" id="module-Make"><a href="#module-Make" class="anchor"></a><code><span><span class="keyword">module</span> <a href="Make/index.html">Make</a></span><span> (<a href="Make/argument-1-_/index.html">_</a> : <span class="keyword">sig</span> ... <span class="keyword">end</span>) : <span class="keyword">sig</span> ... <span class="keyword">end</span></span></code></div><div class="spec-doc"><p>The <code>Make</code> functor is used to generate a reduction function for shapes.</p></div></div><div class="odoc-spec"><div class="spec value anchored" id="val-local_reduce"><a href="#val-local_reduce" class="anchor"></a><code><span><span class="keyword">val</span> local_reduce : <span><a href="../Env/index.html#type-t">Env.t</a> <span class="arrow">&#45;&gt;</span></span> <span><a href="../Shape/index.html#type-t">Shape.t</a> <span class="arrow">&#45;&gt;</span></span> <a href="../Shape/index.html#type-t">Shape.t</a></span></code></div><div class="spec-doc"><p><code>local_reduce</code> will not reduce shapes that require loading external compilation units.</p></div></div><div class="odoc-spec"><div class="spec value anchored" id="val-local_reduce_for_uid"><a href="#val-local_reduce_for_uid" class="anchor"></a><code><span><span class="keyword">val</span> local_reduce_for_uid : <span><a href="../Env/index.html#type-t">Env.t</a> <span class="arrow">&#45;&gt;</span></span> <span><a href="../Shape/index.html#type-t">Shape.t</a> <span class="arrow">&#45;&gt;</span></span> <a href="#type-result">result</a></span></code></div><div class="spec-doc"><p><code>local_reduce_for_uid</code> will not reduce shapes that require loading external compilation units.</p></div></div></div></body></html>