The "Python API enumerators and constants" page was added by
3cae8b3329 as an explicit stop-gap: its contents were grepped out of
the headers by hand, with the few available doc strings copied over
manually. That commit noted the real fix would be a tool that parses the
enum/constant headers and emits the page automatically.
Being hand-maintained, the page drifted badly out of sync. By now it was
missing 19 enums and 60+ enumerators, still documented three values that
no longer exist, and carried stale descriptions.
Add gen-python-api-enums.py, which parses lldb-enumerations.h and
lldb-defines.h and emits the page at build time. It is pulled into
python_api_enums.md via the {build-include} directive, the same
mechanism already used for the generated settings page, so the page can
stay in sync with the source.
Enums from the separately generated SBLanguages.h (eLanguageName*) are
still not covered, matching the previous page's scope.
Assisted-by: Claude
15 lines
464 B
Markdown
15 lines
464 B
Markdown
---
|
|
orphan: true
|
|
---
|
|
|
|
% This is a sub page of the Python API docs and linked from the main API page.
|
|
% The page isn't in any toctree, so silence the sphinx warnings by marking it as orphan.
|
|
|
|
% The page contents are generated at build time from lldb-enumerations.h and
|
|
% lldb-defines.h by lldb/scripts/gen-python-api-enums.py. Don't edit it by hand;
|
|
% update those headers instead.
|
|
|
|
```{build-include} generated-python-api-enums.md
|
|
:parser: myst_parser.sphinx_
|
|
```
|