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

The stored form of a return_policy annotation: a return-value policy, optionally scoped to some languages. More...

#include <welder/annotations.hpp>

Public Attributes

unsigned mask = 0
 The languages to apply to; 0 == all languages.
rv_kind kind = rv_kind::automatic
 The chosen policy.

Detailed Description

The stored form of a return_policy annotation: a return-value policy, optionally scoped to some languages.

Like a scoped weld_as it pairs a language mask (0 == all languages) with its payload — here the welder::rv_kind rather than a name — so a callable can take one policy in Python and another (or none) in Lua. Not templated, so the reflection layer reads it with the plain annotations_of_with_type idiom.

Definition at line 351 of file annotations.hpp.

Member Data Documentation

◆ kind

rv_kind welder::detail::return_policy_spec::kind = rv_kind::automatic

The chosen policy.

Definition at line 353 of file annotations.hpp.

◆ mask

unsigned welder::detail::return_policy_spec::mask = 0

The languages to apply to; 0 == all languages.

Definition at line 352 of file annotations.hpp.


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