www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - DDoc generation at module level

reply Derek Parnell <derek psych.ward> writes:
The following code generates the 'DATE' output correctly ...

 /**
 *   Summary text
 */

 /**
   date: Sep 20, 2005
 */

 module doctest;

However, the following code fails to generate the 'DATE' output ...

 /**
 *   Summary text
 */

 module doctest;

 /**
   date: Sep 20, 2005
 */


In fact, it appears that no module-level documentation is generated after
the first non-documentation text occurs.


This is a problem because it makes the version statement useless for
generation.  Eg...

version(XYZ)
{
   /****
     Licence: whatever ...
   */
}

        
-- 
Derek
(skype: derek.j.parnell)
Melbourne, Australia
20/09/2005 3:35:31 PM
Sep 19 2005
parent reply "Walter Bright" <newshound digitalmars.com> writes:
"Derek Parnell" <derek psych.ward> wrote in message
news:b06fjaa96qvb.1k9xaxnjx840d$.dlg 40tude.net...
 In fact, it appears that no module-level documentation is generated after
 the first non-documentation text occurs.

Actually, module-level documentation is all the documentation comments that appears before the module declaration. I believe this is as it should be, as documentation attached to another declaration should be for that declaration, not the module.
Sep 23 2005
parent Derek Parnell <derek psych.ward> writes:
On Fri, 23 Sep 2005 11:33:36 -0700, Walter Bright wrote:

 "Derek Parnell" <derek psych.ward> wrote in message
 news:b06fjaa96qvb.1k9xaxnjx840d$.dlg 40tude.net...
 In fact, it appears that no module-level documentation is generated after
 the first non-documentation text occurs.

Actually, module-level documentation is all the documentation comments that appears before the module declaration. I believe this is as it should be, as documentation attached to another declaration should be for that declaration, not the module.

How I stumbled across this effect was when I used a version statement to generate alternate documentation. For example .... version(Windows) { /** . . . */ } else { . . . } -- Derek Parnell Melbourne, Australia 24/09/2005 6:14:02 AM
Sep 23 2005