raberu v1.1.0
Fancy Named Parameter Library
 
Loading...
Searching...
No Matches
rbr::flag_keyword< ID > Struct Template Reference

Flag keyword. More...

#include <raberu/impl/keywords.hpp>

Detailed Description

template<typename ID>
struct rbr::flag_keyword< ID >

Flag keyword.

A Flag keyword is a keyword which value is given by its mere presence. It accepts no binding and return a value convertible to bool when set in a rbr::settings.

By design, a flag is also its own rbr::option.

Template Parameters
IDUnique identifier for the keyword

Public Types

using id_type = ID
 ID type associated to the keyword.
 

Related Functions

(Note that these are not member functions.)

template<typename Tag >
constexpr flag_keyword< Tag > flag (Tag id) noexcept
 Create a flag keyword for reuse.
 
template<str ID>
constexpr auto operator""_fl () noexcept
 Forms an instance of rbr::flag_keyword from a literal string.