ECSTASY
All in the name
Loading...
Searching...
No Matches
is_size_t_convertible.hpp
Go to the documentation of this file.
1
11
12#ifndef UTIL_META_IS_STD_SIZE_T_CONVERTIBLE_HPP_
13#define UTIL_META_IS_STD_SIZE_T_CONVERTIBLE_HPP_
14
15#include <concepts>
16#include <type_traits>
17
18namespace util::meta
19{
20
29 template <typename T>
31 std::same_as<T, std::size_t> || requires(T value) { static_cast<std::size_t>(value); };
32
33} // namespace util::meta
34
35#endif /* !UTIL_META_IS_STD_SIZE_T_CONVERTIBLE_HPP_ */
Check if a type is std::size_t or is convertible to it.
Namespace regrouping all meta programmation helper types.