d-programming-language.com

Adam D. Ruppe destructionator at gmail.com
Mon Dec 12 07:04:37 PST 2011


On Monday, 12 December 2011 at 12:10:29 UTC, Jacob Carlborg wrote:
> Wouldn't it be better if ddoc generate the correct HTML from 
> the beginning.

I touched upon this in another post... I say both yes and no.

Yes because it'd be nice. A table of contents seems generally
useful, and correct anchors and reference macros are braindead.
(I'll see about implementing the name macros myself eventually.)

But, no because I think it's going to complicate ddoc and still
not cover everything. Suppose we add macros for the table of
contents. What if we then want to add category sorting? That
was an extra about 5 lines in my program, but I think it'd be
fairly complex inside ddoc itself.


Basically I view ddoc as being a parser that just happenes to
be able to do human readable output.. but the real goal, in my
mind, is to process it into something a computer can read back in
easily to produce the final product.

So, ddoc should make available all the information is has, but
not necessarily do any formatting of it.


More information about the Digitalmars-d mailing list