Commit 27b431d
authored
Fix rendering of google-style docstring in sphinx docs (#247)
Context of this PR:
llvm/llvm-project#167063 (comment)
The current MLIR Python Sphinx documentation cannot handle functions
that use Google-style docstrings. In this PR, we introduce support for
this feature, allowing Google-style docstrings to be properly converted
into reStructuredText.
Before:
<img width="1490" height="1147" alt="image"
src="https://github.com/user-attachments/assets/79e99552-c827-41f8-b917-02a056d76edd"
/>
After:
<img width="1514" height="1492" alt="image"
src="https://github.com/user-attachments/assets/1f22ae25-fbdc-4ee1-8c32-dac58585e32e"
/>
Preview it at:
https://mlir-python-googledocstring.surge.sh/autoapi/mlir/_mlir_libs/_mlir/ir/index.html
cc @makslevental @jpienaar1 parent 8e64ddb commit 27b431d
1 file changed
+15
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
38 | 38 | | |
39 | 39 | | |
40 | 40 | | |
| 41 | + | |
41 | 42 | | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
42 | 47 | | |
43 | | - | |
| 48 | + | |
44 | 49 | | |
45 | 50 | | |
46 | 51 | | |
47 | | - | |
48 | | - | |
49 | | - | |
50 | | - | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
51 | 61 | | |
52 | 62 | | |
53 | 63 | | |
| |||
0 commit comments