welder 0.1.0
Bindings for annotated C++ types, from C++26 reflection
Loading...
Searching...
No Matches
welder::doc_style Concept Reference

A style folds a welder::detail::function_doc into one docstring. More...

#include <welder/concepts.hpp>

Concept definition

template<class S>
concept doc_style = requires(const detail::function_doc& d) {
{ S::format(d) } -> std::same_as<std::string>;
}
A style folds a welder::detail::function_doc into one docstring.
Definition concepts.hpp:366
The raw documentation pieces of a function, handed to a style to assemble.
Definition doc.hpp:253

Detailed Description

A style folds a welder::detail::function_doc into one docstring.

It is the customization point for how documentation reads in the target language; swap it to emit Google-, NumPy-, or any house style. Any type with static std::string format(const detail::function_doc&) qualifies. Concrete styles live with the rods that share them (e.g. welder::rods::python::google_style in <welder/rods/python/doc_style.hpp>), keeping this core layer neutral.

Template Parameters
Sthe candidate style type.

Definition at line 366 of file concepts.hpp.