|
constexpr auto | parse (format_parse_context &ctx) -> decltype(ctx.begin()) |
|
template<typename FormatContext > |
auto | format (const std::optional< T > &input, FormatContext &ctx) -> decltype(ctx.out()) |
|
template<typename T>
struct fmt::formatter< std::optional< T > >
Definition at line 37 of file logging.hpp.
◆ format()
template<typename T >
template<typename FormatContext >
auto fmt::formatter< std::optional< T > >::format |
( |
const std::optional< T > & |
input, |
|
|
FormatContext & |
ctx |
|
) |
| -> decltype(ctx.out()) |
|
inline |
Definition at line 41 of file logging.hpp.
41 {
42 if (input.has_value())
43 return fmt::format_to(ctx.out(), "{}", input.value());
44 return fmt::format_to(ctx.out(), "<EMPTY>");
45 }
◆ parse()
template<typename T >
constexpr auto fmt::formatter< std::optional< T > >::parse |
( |
format_parse_context & |
ctx | ) |
-> decltype(ctx.begin()) |
|
inlineconstexpr |
The documentation for this struct was generated from the following file: