← Back to team overview

dolfin team mailing list archive

Re: C++ header parser for generation of documentation

 

Looks very useful. Can you add it as a blueprint?

--
Anders


On Wed, Jun 13, 2012 at 11:22:07AM +0200, Johan Hake wrote:
> Hello!
>
> Kristian implemented our own C++ header parser in python to extract
> documentation and signatures. It is slow and for all I know not
> complete.
>
> I just found a recent python library, which seems to be fast (based
> on David Beazely's ply implementation of a lex/yacc parser) and
> pretty complete.
>
>   http://sourceforge.net/projects/cppheaderparser
>
> While I do not see any urgent need to re-implement Kristian's hard
> work of extracting signatures and documentation to be piped to
> Sphinx I think it should be considered for possible future work.
>
> For a fast intro of the capability:
>
> sudo apt-get install python-lex python-pip
> pip install CppHeaderParser
>
> cd $DOLFIN_DIR
> python -c 'import CppHeaderParser;
> CppHeaderParser.CppHeader("dolfin/mesh/Mesh.h").show()'
>
> All classes and methods with documentation and complete signatures
> are iterable.
>
> Johan
>
> _______________________________________________
> Mailing list: https://launchpad.net/~dolfin
> Post to     : dolfin@xxxxxxxxxxxxxxxxxxx
> Unsubscribe : https://launchpad.net/~dolfin
> More help   : https://help.launchpad.net/ListHelp


Follow ups

References