Example:
/**
$1 $2
---
string s = "$1$2 $ $4";
---
*/
void foo(){}
Produces this (note that a lone $ was keept intact and $ doesn't work inside pre block):
<html><head>
<META http-equiv="content-type" content="text/html; charset=utf-8">
<title>test</title>
</head><body>
<h1>test</h1>
<!-- Generated by Ddoc from test.d -->
<br><br>
<dl><dt><big>void <u>foo</u>();
</big></dt>
<dd>$1 $2
<pre class="d_code">string s = <font color=red>" $ &#36;4"</font>;
</pre>
<br><br>
</dd>
</dl>
<hr><small>Page generated by <a href="http://www.digitalmars.com/d/2.0/ddoc.html">Ddoc</a>. </small>
</body></html>
Marking as critical because it destroys the replace format string in regex article. But maybe, just maybe, I'm missing something.
Comment #1 by dmitry.olsh — 2012-03-15T09:37:19Z
As there is a workaround via macro:
DOLLAR = $
I'm lowering importance, but the point is that I for one expect any D code inside
---
...
---
to be protected from whatever macroses/DDoc specifics.
Comment #2 by andrej.mitrovich — 2012-12-02T08:58:39Z