Re: DocBook function synopsis

Subject: Re: DocBook function synopsis
From: Lionel Mallet <l.mallet@xxxxxxxxxxxxx>
Date: Thu, 09 Jul 1998 08:53:41 +0200
On Thu, 09 Jul 1998 12:42:13 +0900, "Frank A. Christoph" 
<christo@xxxxxxxxxxxxxxxxxx>  wrote:
> I wasn't planning on making any major changes, just enough that I can handle
> pure and const member functions.  Anyway, here is a first shot, sufficient
> for my purposes. (This is the result of about 15 minutes work, so if someone
> has any better ideas, or if it turns out that I'm "violating the spirit of
> Docbook" in some way, I'll be happy to entertain other ideas.)
> 
> I added three attributes to FuncDef in the declaration subset, "Class" which
> indicates what class the function is a member of (I'm not using it, but it
> seems potentially useful); "Dispatch" which would be "pure" for pure virtual
> functions, "virtual" for regular dynamically dispatched functions, and
> "static" for statically dispatched functions; and finally "Const" which is
> "const" for functions that don't modify the state, or "mutable" for those
> that do.

I'm not sure if this breaks the spirit of DocBook but I'm sure this is not 
scalable enough to handle any other language than C and C++.
I already had this problem with DocBook when I wrote some Java classes 
documentation using it as a base DTD. Think of how you would define that the 
function throws an exception.

I think a good solution would have to start from the grammars of the various 
targeted languages and extract some generic pieces of information in a 
function declaration to define the appropriate elements (not attributes) in a 
<funcsynopsis>.

I hope those 2 cents of my own thoughts would help.
-- 
Lionel Mallet                           E-mail: l.mallet@xxxxxxxxxxxxx
The Open Group Research Institute       Phone: +33 (0) 476 63 48 66
2, Av. de Vignate                       Fax:   +33 (0) 476 51 05 32
F38610 - Gieres, France                 



 DSSSList info and archive:  http://www.mulberrytech.com/dsssl/dssslist


Current Thread
  • DocBook function synopsis
    • Frank A. Christoph - from mail1.ability.netby web4-1.ability.net (8.8.5/8.6.12) with ESMTP id WAA18410Sun, 5 Jul 1998 22:55:30 -0400 (EDT)
      • <Possible follow-ups>
      • Frank A. Christoph - from mail1.ability.netby web4-1.ability.net (8.8.5/8.6.12) with ESMTP id XAA29146Tue, 7 Jul 1998 23:13:17 -0400 (EDT)
        • Norman Walsh - from mail1.ability.netby web4-1.ability.net (8.8.5/8.6.12) with ESMTP id IAA12156Wed, 8 Jul 1998 08:15:53 -0400 (EDT)
      • Frank A. Christoph - from mail1.ability.netby web4-1.ability.net (8.8.5/8.6.12) with ESMTP id XAA11708Wed, 8 Jul 1998 23:33:04 -0400 (EDT)
        • Lionel Mallet - from mail1.ability.netby web4-1.ability.net (8.8.5/8.6.12) with ESMTP id DAA16760Thu, 9 Jul 1998 03:02:38 -0400 (EDT) <=
        • Mitch C. Amiano - from mail1.ability.netby web4-1.ability.net (8.8.5/8.6.12) with ESMTP id RAA02041Thu, 9 Jul 1998 17:03:33 -0400 (EDT)
      • Frank A. Christoph - from mail1.ability.netby web4-1.ability.net (8.8.5/8.6.12) with ESMTP id DAA20422Thu, 9 Jul 1998 03:45:12 -0400 (EDT)
      • Frank A. Christoph - from mail1.ability.netby web4-1.ability.net (8.8.5/8.6.12) with ESMTP id WAA27256Thu, 9 Jul 1998 22:45:28 -0400 (EDT)
        • Mitch C. Amiano - from mail1.ability.netby web4-1.ability.net (8.8.5/8.6.12) with ESMTP id KAA13750Fri, 10 Jul 1998 10:23:10 -0400 (EDT)