Iros
 
Loading...
Searching...
No Matches
as_bool.h
Go to the documentation of this file.
1#pragma once
2
6#include "di/util/forward.h"
7
8namespace di::function {
10 template<concepts::ConvertibleTo<bool> T>
11 constexpr auto operator()(T&& value) const -> bool {
12 return static_cast<bool>(util::forward<T>(value));
13 }
14};
15
16constexpr inline auto as_bool = AsBool {};
17}
18
19namespace di {
21using function::AsBool;
22}
Definition as_bool.h:8
constexpr auto as_bool
Definition as_bool.h:16
constexpr auto value
Definition value.h:34
Definition zstring_parser.h:9
Definition as_bool.h:9
constexpr auto operator()(T &&value) const -> bool
Definition as_bool.h:11