Skip to main content

A sphinx autodoc extension for c modules

Project description

Build Status Coverage Code Style Documentation Status

A basic attempt at extending Sphinx and autodoc to work with C files.

The idea is to add support for similar directives that autodoc provides. i.e.

A function in my_c_file.c:

/**
 * A simple function that adds.
 *
 * @param a: The initial value
 * @param b: The value to add to `a`
 *
 * @returns The sum of `a` and `b`.
 *
 *
int my_adding_function(int a, int b) {
    return a + b;
    }

Could be referenced in documentation as:

.. autocfunction:: my_c_file.c::my_adding_function

With the resulting documentation output of:

.. c:function:: int my_adding_function(int a, int b)

A simple function that adds.

:param a: The initial value
:param b: The value to add to `a`
:returns: The sum of `a` and `b`

Similar Tools

  • hawkmoth a sphinx extension that which will document all of a C file. It supports being able to regex list files and have those files be documented.
  • breathe A doxygen output to sphinx tool.

Full Documentation

The complete documentation can be found at https://sphinx-c-autodoc.readthedocs.io/en/latest

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for sphinx-c-autodoc, version 0.1.1
Filename, size File type Python version Upload date Hashes
Filename, size sphinx_c_autodoc-0.1.1-py3-none-any.whl (21.7 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size sphinx-c-autodoc-0.1.1.tar.gz (19.7 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page