haxscramper / hcparse

High-level nim bindings for parsing C/C++ code
https://haxscramper.github.io/hcparse-doc/src/hcparse/libclang.html
Apache License 2.0
37 stars 2 forks source link

Automatically merge documentation into generated sources #16

Open haxscramper opened 2 years ago

haxscramper commented 2 years ago

Current nim doc has very anemic support for any kind of metadata annotations (i.e. there is no support at all), but ideally I want to use haxdoc as a "recommended" documentation generator for wrappers, so it is not problematic.

Most C and C++ libraries use Doxygen, qdoc, mandoc or texinfo for documentation. Right now, I have wrappers for Doxygen XML parsers (dox_compound and dox_index) and somewhat broken wrappers for mandoc format.

An earlier version of qdoc could output XML, but this feature has been removed. There seems to be an available API for working with qdoc AST, though, which makes things noticeably simpler.

Texinfo also has something resembling an API.

Related - https://github.com/haxscramper/haxdoc/issues/6 and https://github.com/haxscramper/haxdoc/issues/5

haxscramper commented 2 years ago

Generation of the org-mode/haxdoc comments seems like an optimal solution. I can later add support for nim doc.