ocaml-trace/ppxlib/Ppxlib/Driver/Instrument/index.html
2025-12-12 13:56:43 +00:00

5 lines
3 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>Instrument (ppxlib.Ppxlib.Driver.Instrument)</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">ppxlib</a> &#x00BB; <a href="../../index.html">Ppxlib</a> &#x00BB; <a href="../index.html">Driver</a> &#x00BB; Instrument</nav><header class="odoc-preamble"><h1>Module <code><span>Driver.Instrument</span></code></h1></header><div class="odoc-content"><div class="odoc-spec"><div class="spec type anchored" id="type-t"><a href="#type-t" class="anchor"></a><code><span><span class="keyword">type</span> t</span></code></div></div><div class="odoc-spec"><div class="spec type anchored" id="type-pos"><a href="#type-pos" class="anchor"></a><code><span><span class="keyword">type</span> pos</span><span> = </span></code><ol><li id="type-pos.Before" class="def variant constructor anchored"><a href="#type-pos.Before" class="anchor"></a><code><span>| </span><span><span class="constructor">Before</span></span></code></li><li id="type-pos.After" class="def variant constructor anchored"><a href="#type-pos.After" class="anchor"></a><code><span>| </span><span><span class="constructor">After</span></span></code></li></ol></div></div><div class="odoc-spec"><div class="spec value anchored" id="val-make"><a href="#val-make" class="anchor"></a><code><span><span class="keyword">val</span> make :
<span><span>(<span><a href="../../../Astlib/Ast_502/Parsetree/index.html#type-structure">Ppxlib_ast.Parsetree.structure</a> <span class="arrow">&#45;&gt;</span></span> <a href="../../../Astlib/Ast_502/Parsetree/index.html#type-structure">Ppxlib_ast.Parsetree.structure</a>)</span> <span class="arrow">&#45;&gt;</span></span>
<span><span class="label">position</span>:<a href="#type-pos">pos</a> <span class="arrow">&#45;&gt;</span></span>
<a href="#type-t">t</a></span></code></div><div class="spec-doc"><p><code>make transformation ~position</code> creates an instrumentation that can be passed to <code>Driver.register_transformation</code> to instrument an implementation file. <code>transformation</code> is the transformation that will be applied to the AST; <code>position</code> specifies if it should be applied before or after rewriters defined through <code>rules</code>, <code>impl</code> or <code>intf</code> are applied.</p></div></div><div class="odoc-spec"><div class="spec module anchored" id="module-V2"><a href="#module-V2" class="anchor"></a><code><span><span class="keyword">module</span> <a href="V2/index.html">V2</a></span><span> : <span class="keyword">sig</span> ... <span class="keyword">end</span></span></code></div></div></div></body></html>