welder 0.1.0
Bindings for annotated C++ types, from C++26 reflection
Loading...
Searching...
No Matches
welder::detail::enum_doc Struct Reference

The raw documentation pieces of an enum, handed to a style to assemble. More...

#include <welder/doc.hpp>

Public Attributes

const char * summary {nullptr}
 The enum's own doc.
std::span< const enumerator_docmembers {}
 Documented, bound enumerators, in declaration order.

Detailed Description

The raw documentation pieces of an enum, handed to a style to assemble.

An enum has no per-enumerator docstring slot the Python doc tools surface (a stub lists a member as a bare Name = value), so a documented enumerator's text is folded into the enum's class docstring as an Attributes section — the one place pybind11-stubgen/nanobind's stub generator carries it into the .pyi. The style decides that section's spelling (Google Attributes:, NumPy underlined Attributes, Sphinx :var:); this struct is the neutral input, a sibling of function_doc. The carriage gathers the (participation-filtered, styled-named) enumerator list; the rod's DocStyle::format_enum folds it.

Definition at line 277 of file doc.hpp.

Member Data Documentation

◆ members

std::span<const enumerator_doc> welder::detail::enum_doc::members {}

Documented, bound enumerators, in declaration order.

Definition at line 279 of file doc.hpp.

◆ summary

const char* welder::detail::enum_doc::summary {nullptr}

The documentation for this struct was generated from the following file: