mirror of
https://github.com/ocaml-tracing/ocaml-trace.git
synced 2026-03-09 12:23:32 -04:00
2 lines
No EOL
2 KiB
HTML
2 lines
No EOL
2 KiB
HTML
<!DOCTYPE html>
|
||
<html xmlns="http://www.w3.org/1999/xhtml"><head><title>Reserved_namespaces (ppxlib.Ppxlib.Reserved_namespaces)</title><link rel="stylesheet" href="../../../_odoc-theme/odoc.css"/><meta charset="utf-8"/><meta name="generator" content="odoc 2.2.2"/><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">ppxlib</a> » <a href="../index.html">Ppxlib</a> » Reserved_namespaces</nav><header class="odoc-preamble"><h1>Module <code><span>Ppxlib.Reserved_namespaces</span></code></h1><p>Small module to reserve namespaces in attribute names.</p></header><div class="odoc-content"><div class="odoc-spec"><div class="spec value anchored" id="val-reserve"><a href="#val-reserve" class="anchor"></a><code><span><span class="keyword">val</span> reserve : <span>string <span class="arrow">-></span></span> unit</span></code></div><div class="spec-doc"><p><code>reserve "foo"</code> has two implications:</p><ul><li>one can't then declare an attribute inside this namespace</li><li>attributes within this namespace won't be reported by <code>check_unused</code></li></ul><p>This is here to insure that the rewriter cohabits well with other rewriter or tools (e.g. merlin) which might leave attribute on the AST.</p><p>N.B. the following namespaces are reserved by default: <code>merlin</code>, <code>reason</code>, <code>refmt</code> <code>ns</code>, <code>res</code>, <code>metaocaml</code>, <code>ocamlformat</code> and <code>ppxlib</code>.</p></div></div><div class="odoc-spec"><div class="spec value anchored" id="val-is_in_reserved_namespaces"><a href="#val-is_in_reserved_namespaces" class="anchor"></a><code><span><span class="keyword">val</span> is_in_reserved_namespaces : <span>string <span class="arrow">-></span></span> bool</span></code></div></div></div></body></html> |