-
Notifications
You must be signed in to change notification settings - Fork 385
Open
Labels
Description
The Sphinx-generated documentation includes using autodoc on functions/methods, which are overloaded through multimethod. For methods (such as Location.__init__), that works just fine. The feature is enabled through doc/ext/sphinx_autodoc_multimethod.py.
However, for multimethod functions defined at the toplevel of a module, the documentation is broken:
- edgeOn appears strange (docstring/prototype of overloaded function is just placed as-is) and raises an Inline emphasis start-string without end-string warning in build_docs.sh. The asterix marking a list of arguments in a secondary definition is interpreted wrong.
- loft has exactly the same issues.
- wire I guess only works, because the overloaded function has no docstring.
- face appears strange with docstring/prototype of overloaded function placed as-is, but raises no Sphinx warning.
- These functions have the same issue like face
I guess doc/ext/sphinx_autodoc_multimethod.py needs fixing. But to be honest, I don't understand in-detail how this Sphinx extension works, and my attempts to fix it failed. The extension was created and edited by @lorenzncode. I browsed through past PRs and issues related to the history of the Sphinx extension, but none refers explicitly to module-level functions.