]> git.ipfire.org Git - thirdparty/libvirt.git/commit
Fix API doc extractor to stop munging comment formatting
authorDaniel P. Berrange <berrange@redhat.com>
Fri, 25 Sep 2009 12:24:40 +0000 (13:24 +0100)
committerDaniel P. Berrange <berrange@redhat.com>
Mon, 28 Sep 2009 13:08:25 +0000 (14:08 +0100)
commit5486abfe4ede6a649561de2b6f829c2bba908f2c
tree4ad92ebdd0c5f9fc68c22b8e672103fcd28574aa
parentd104362d90dbe186dfb22644c65eb44181433fba
Fix API doc extractor to stop munging comment formatting

The python method help docs are copied across from the C
funtion comments, but in the process all line breaks and
indentation was being lost. This made the resulting text
and code examples completely unreadable. Both the API
doc extractor and the python generator were destroying
whitespace & this fixes them to preserve it exactly.

* docs/apibuild.py: Preserve all whitespace when extracting
  function comments. Print function comment inside a <![CDATA[
  section to fully preserve all whitespace. Look for the
  word 'returns' to describe return values, instead of 'return'
  to avoid getting confused with code examples including the
  C 'return' statement.
* python/generator.py: Preserve all whitespace when printing
  function help docs
* src/libvirt.c: Change any return parameter indicated by
  'return' to be 'returns', to avoid confusing the API extractor
* docs/libvirt-api.xml: Re-build for fixed descriptions
docs/apibuild.py
docs/libvirt-api.xml
python/generator.py
src/libvirt.c