[GCC-XML]Various bits not mentioned in XML output

Mike Capp aphelion at clara.co.uk
Sun Mar 9 16:12:32 EST 2003


Hi,

I'm currently trying to work out whether GCCXML could be used as the parser 
for a documentation generator along the lines of JavaDoc or Doxygen. 
Obviously I'd need a separate preprocessor to grab the doc comments, but 
that's trivial; the real question is about various aspects of C++ source 
which aren't currently output as XML. In most cases the missing bits would 
be of no interest to a compiler back-end, so I'm worried that the GCC 
parser just doesn't support them.

In particular:

- Typedefs are output as <Typedef> elements, but never seem to be 
referenced. A typedef function argument will be output as an <Argument> 
with the typedef's underlying type.

- Declarations (specifically, function prototypes) are not output as XML 
unless there's no corresponding definition, in which case they're written 
with an extern="1" attribute. Would it be possible to output declarations 
even when a definition *is* found, with a prototype="1" or somesuch to 
distinguish the two?

- File-scope static (as opposed to class-member static) is not marked. (I'm 
fairly sure I've seen a "linkage_kind" or somesuch in the GCC source, but 
it may be new; they have a completely rewritten C++ frontend now.)

Cheers,
Mike




More information about the gccxml mailing list