-D option = Embedded documentation

Timon Gehr timon.gehr at gmx.ch
Fri Dec 16 09:40:52 PST 2011

On 12/16/2011 06:12 PM, dune wrote:
> What?
> Sorry but I don't understand...
> What I posted was an example, in reality there is tons of code inside the d file.
> Thanks

That is not what you said. Obviously you should always give an example 
that actually fails, especially when you claim it does.

$ cat worksforme.d
  * documentation here
module worksforme;

/// program entry point
void main(){}

$ dmd -D worksforme
$ cat worksforme.html
         <META http-equiv="content-type" content="text/html; charset=utf-8">
         <!-- Generated by Ddoc from worksforme.d -->
documentation here<br><br>

<dl><dt><big>void <u>main</u>();
<dd>program entry point<br><br>


         <hr><small>Page generated by <a 
href="http://www.digitalmars.com/d/2.0/ddoc.html">Ddoc</a>. </small>

More information about the Digitalmars-d-learn mailing list