[dmd-beta] 64 bit beta for Linux

Jonathan M Davis jmdavisProg at gmx.com
Sun Feb 6 17:25:02 PST 2011


On Sunday 06 February 2011 17:08:35 Rainer Schuetze wrote:
> Jonathan M Davis wrote:
> > Do _not_ expect your code to work if you compile with ddoc enabled.
> 
> That's what I was afraid of ;-) The dmd command line interface suggests
> that you could do so, and so does Visual D. I'd hate to do have to split
> it into two commands, as this will probably double the compilation time.

There's too much that has to be special cased for ddoc to be used for a normal 
build. For instance, if you want the documentation to be able to build on 
multiple platforms (which unfortunately, Phobos wasn't doing, but some of it now 
is), you _have_ to have a separate version(D_Ddoc) section in many cases. Also, 
in cases where you want to be able to clean up the documentation (std.algorithm 
would be a good candidate, for instance), you may be forced to have a separate, 
simplified version just for ddoc generation. So, ultimately, it just doesn't work 
to build the documentation as part of a normal build. However, it _is_ a mistake 
that I expect that many people will make. _I_ made it before I came to better 
understand the situation. But it quickly becomes obvious once you have code 
which is OS-specific, and you want to the same docs to be generated on all OSes.

On the bright side, ddoc builds will generally be faster than other builds 
because many of the functions will be stubs (at least, if the code in question 
uses version(D_Ddoc) at all like Phobos does).

- Jonathan M Davis


More information about the dmd-beta mailing list