Support Class Library
A set of tools providing classes and utility
|
A namespace englobing all the TMP tools. More...
Namespaces | |
details | |
Namespace for implementation details for TMP. | |
Classes | |
struct | fn |
struct | fn< F, decltype(&F::operator())> |
struct | fn< R(*)(Args...), void > |
struct | fn< R(Class::*const)(Args...), std::nullptr_t > |
struct | fn< R(Class::*const)(Args...), void > |
struct | function_traits |
Traits for callable types. More... | |
struct | function_traits< std::function< R(Args...)> > |
Specialization for std::function. More... | |
struct | real_const |
Get the appropriate const version of a type. More... | |
struct | real_const< T *, void > |
Specialization for pointers. More... | |
Typedefs | |
template<bool B, class T , class F > | |
using | conditional_t = typename std::conditional< B, T, F >::type |
An handy type alias for the result of std::conditional. More... | |
template<bool B, class T = void> | |
using | enable_if_t = typename std::enable_if< B, T >::type |
An handy type alias for the result of std::enable_if. More... | |
template<class T > | |
using | return_t = typename function_traits< T >::return_type |
template<class T , size_t i> | |
using | arg_t = typename function_traits< T >::template arg_t< i > |
template<class F > | |
using | fn_t = fn< F, void > |
template<class F > | |
using | std_fn_type = typename fn_t< F >::fn_type |
template<class Ret , class... Args> | |
using | fn_type = Ret(*)(Args...) |
An handy type alias to describe function pointer types. More... | |
template<class Ret , class Class , class... Args> | |
using | memfn_type = Ret(Class::*)(Args...) |
An handy type alias to describe member function pointer types. More... | |
template<class Ret , class Class , class... Args> | |
using | const_memfn_type = Ret(Class::*)(Args...) const |
template<class Ret , class Class > | |
using | mem_ptr_type = Ret Class::* |
template<class Ret , class... Args> | |
using | fn_sig_type = Ret(Args...) |
template<class T > | |
using | real_const_t = typename real_const< T >::type |
template<class T > | |
using | remove_cv_t = typename std::remove_cv< T >::type |
template<class T > | |
using | remove_const_t = typename std::remove_const< T >::type |
template<class T > | |
using | remove_volatile_t = typename std::remove_volatile< T >::type |
template<class T > | |
using | add_cv_t = typename std::add_cv< T >::type |
template<class T > | |
using | add_const_t = typename std::add_const< T >::type |
template<class T > | |
using | add_volatile_t = typename std::add_volatile< T >::type |
template<class T > | |
using | remove_reference_t = typename std::remove_reference< T >::type |
template<class T > | |
using | add_lvalue_reference_t = typename std::add_lvalue_reference< T >::type |
template<class T > | |
using | add_rvalue_reference_t = typename std::add_rvalue_reference< T >::type |
template<class T > | |
using | remove_pointer_t = typename std::remove_pointer< T >::type |
template<class T > | |
using | add_pointer_t = typename std::add_pointer< T >::type |
template<class T > | |
using | make_signed_t = typename std::make_signed< T >::type |
template<class T > | |
using | make_unsigned_t = typename std::make_unsigned< T >::type |
template<class T > | |
using | remove_extent_t = typename std::remove_extent< T >::type |
template<class T > | |
using | remove_all_extents_t = typename std::remove_all_extents< T >::type |
template<class T > | |
using | decay_t = typename std::decay< T >::type |
template<class T > | |
using | remove_cv_ref_t = remove_cv_t< remove_reference_t< T > > |
template<class T > | |
using | no_op_t = typename details::NoOp< T >::type |
template<std::size_t Len, std::size_t Align = sizeof(char)> | |
using | aligned_storage_t = typename std::aligned_storage< Len, Align >::type |
template<std::size_t Len, class... Types> | |
using | aligned_union_t = typename std::aligned_union< Len, Types... >::type |
template<class... T> | |
using | common_type_t = typename std::common_type< T... >::type |
template<class T > | |
using | underlying_type_t = typename std::underlying_type< T >::type |
template<size_t I, class Tuple > | |
using | tuple_element_t = typename std::tuple_element< I, Tuple >::type |
template<class Signature > | |
using | result_of_t = typename std::result_of< Signature >::type |
template<class... > | |
using | void_t = void |
The must have. More... | |
Functions | |
template<class Func , class... Args> | |
constexpr bool | can_call (Func f) |
Determines whether or not the given function can be called with the given argument types. More... | |
template<bool b> | |
constexpr bool | constexpr_assert () |
template<class T > | |
constexpr bool | defines_ostream_operator () |
Determines whether or not the operator<< is defined for the given type and ostream. More... | |
template<class T > | |
constexpr bool | defines_scl_to_string () |
Determines whether or not ToString has been specialized for the given type. More... | |
template<class T > | |
constexpr bool | defines_std_to_string () |
Determines whether or not std::to_string(const T&) is defined. More... | |
template<class T > | |
constexpr bool | exists () |
Determines whether or not the given type is well-formed. More... | |
template<class From , class Ret , class... Args> | |
constexpr fn_type< Ret, Args... > | fn_cast (From f) |
Cast a function from its type to determined type. More... | |
template<class From , class Class , class Ret , class... Args> | |
constexpr memfn_type< Class, Ret, Args... > | fn_cast (From f) |
Cast a member function from its type to determined type. More... | |
template<class R , class... Args> | |
std_fn_type< R(*)(Args...)> | as_fn (R(*f)(Args...)) |
template<class Class , class R , class... Args> | |
std_fn_type< R(Class::*const)(Args...)> | as_fn (R(Class::*const f)(Args...) const) |
template<class F > | |
fn< F, void >::fn_type | as_fn (F f) |
template<class Base , class Derived > | |
constexpr bool | is_base_of () |
An handy function for the result of std::is_base_of. More... | |
template<class From , class To > | |
constexpr bool | is_convertible () |
An handy function for the result of std::is_convertible. More... | |
template<template< class, class... > class U, class... T> | |
constexpr bool | is_instance () |
Determines whether a template type is an "instance" of a templated type. More... | |
template<class Lhs , class Rhs > | |
constexpr bool | is_same () |
An handy function for the result of std::is_same. More... | |
template<class T > | |
constexpr bool | is_swappable () |
template<class T > | |
constexpr bool | is_void () |
template<class T > | |
constexpr bool | is_null_pointer () |
template<class T > | |
constexpr bool | is_integral () |
template<class T > | |
constexpr bool | is_floating_point () |
template<class T > | |
constexpr bool | is_array () |
template<class T > | |
constexpr bool | is_enum () |
template<class T > | |
constexpr bool | is_union () |
template<class T > | |
constexpr bool | is_class () |
template<class T > | |
constexpr bool | is_function () |
template<class T > | |
constexpr bool | is_pointer () |
template<class T > | |
constexpr bool | is_lvalue_reference () |
template<class T > | |
constexpr bool | is_rvalue_reference () |
template<class T > | |
constexpr bool | is_member_object_pointer () |
template<class T > | |
constexpr bool | is_member_function_pointer () |
template<class T > | |
constexpr bool | is_fundamental () |
template<class T > | |
constexpr bool | is_arithmetic () |
template<class T > | |
constexpr bool | is_scalar () |
template<class T > | |
constexpr bool | is_object () |
template<class T > | |
constexpr bool | is_compound () |
template<class T > | |
constexpr bool | is_reference () |
template<class T > | |
constexpr bool | is_member_pointer () |
template<class T > | |
constexpr bool | is_const () |
template<class T > | |
constexpr bool | is_volatile () |
template<class T > | |
constexpr bool | is_trivial () |
template<class T > | |
constexpr bool | is_trivially_copyable () |
template<class T > | |
constexpr bool | is_standard_layout () |
template<class T > | |
constexpr bool | is_empty () |
template<class T > | |
constexpr bool | is_polymorphic () |
template<class T > | |
constexpr bool | is_abstract () |
template<class T > | |
constexpr bool | is_signed () |
template<class T > | |
constexpr bool | is_unsigned () |
template<class T , class... Args> | |
constexpr bool | is_constructible () |
template<class T , class... Args> | |
constexpr bool | is_trivially_constructible () |
template<class T , class... Args> | |
constexpr bool | is_nothrow_constructible () |
template<class T > | |
constexpr bool | is_default_constructible () |
template<class T > | |
constexpr bool | is_trivially_default_constructible () |
template<class T > | |
constexpr bool | is_nothrow_default_constructible () |
template<class T > | |
constexpr bool | is_copy_constructible () |
template<class T > | |
constexpr bool | is_trivially_copy_constructible () |
template<class T > | |
constexpr bool | is_nothrow_copy_constructible () |
template<class T > | |
constexpr bool | is_move_constructible () |
template<class T > | |
constexpr bool | is_trivially_move_constructible () |
template<class T > | |
constexpr bool | is_nothrow_move_constructible () |
template<class T > | |
constexpr bool | is_copy_assignable () |
template<class T > | |
constexpr bool | is_trivially_copy_assignable () |
template<class T > | |
constexpr bool | is_nothrow_copy_assignable () |
template<class T > | |
constexpr bool | is_move_assignable () |
template<class T > | |
constexpr bool | is_trivially_move_assignable () |
template<class T > | |
constexpr bool | is_nothrow_move_assignable () |
template<class T > | |
constexpr bool | is_destructible () |
template<class T > | |
constexpr bool | is_trivially_destructible () |
template<class T > | |
constexpr bool | is_nothrow_destructible () |
template<class T > | |
constexpr bool | has_virtual_destructor () |
template<class T > | |
constexpr bool | is_copyable () |
Determines whether or not a type defines copy semantics. More... | |
template<class T > | |
constexpr bool | is_movable () |
Determines whether or not a type defines move semantics. More... | |
template<class T > | |
constexpr bool | is_trivially_movable () |
Determines whether or not a type defines trivial move semantics. More... | |
template<class F , class... Args> | |
constexpr bool | is_invocable () |
template<class T > | |
constexpr std::size_t | alignment_of () |
template<class T > | |
constexpr std::size_t | rank () |
template<class T , unsigned N = 0> | |
constexpr std::size_t | extent () |
A namespace englobing all the TMP tools.
using scl::tools::meta::add_const_t = typedef typename std:: add_const <T>::type |
Definition at line 17 of file type_mod.h.
using scl::tools::meta::add_cv_t = typedef typename std:: add_cv <T>::type |
Definition at line 16 of file type_mod.h.
using scl::tools::meta::add_lvalue_reference_t = typedef typename std:: add_lvalue_reference <T>::type |
Definition at line 21 of file type_mod.h.
using scl::tools::meta::add_pointer_t = typedef typename std:: add_pointer <T>::type |
Definition at line 25 of file type_mod.h.
using scl::tools::meta::add_rvalue_reference_t = typedef typename std:: add_rvalue_reference <T>::type |
Definition at line 22 of file type_mod.h.
using scl::tools::meta::add_volatile_t = typedef typename std:: add_volatile <T>::type |
Definition at line 18 of file type_mod.h.
using scl::tools::meta::aligned_storage_t = typedef typename std::aligned_storage<Len, Align>::type |
Definition at line 27 of file type_query.h.
using scl::tools::meta::aligned_union_t = typedef typename std::aligned_union<Len, Types...>::type |
Definition at line 30 of file type_query.h.
using scl::tools::meta::arg_t = typedef typename function_traits<T>::template arg_t<i> |
Definition at line 49 of file fn_introspect.h.
using scl::tools::meta::common_type_t = typedef typename std:: common_type <T...>::type |
Definition at line 32 of file type_query.h.
using scl::tools::meta::conditional_t = typedef typename std::conditional<B, T, F>::type |
An handy type alias for the result of std::conditional.
Definition at line 12 of file conditional.h.
using scl::tools::meta::const_memfn_type = typedef Ret(Class::*)(Args...) const |
using scl::tools::meta::decay_t = typedef typename std:: decay <T>::type |
Definition at line 33 of file type_mod.h.
using scl::tools::meta::enable_if_t = typedef typename std::enable_if<B, T>::type |
An handy type alias for the result of std::enable_if.
Definition at line 12 of file enable_if.h.
using scl::tools::meta::fn_sig_type = typedef Ret(Args...) |
using scl::tools::meta::fn_t = typedef fn<F, void> |
Definition at line 83 of file fn_introspect.h.
using scl::tools::meta::fn_type = typedef Ret(*)(Args...) |
using scl::tools::meta::make_signed_t = typedef typename std:: make_signed <T>::type |
Definition at line 27 of file type_mod.h.
using scl::tools::meta::make_unsigned_t = typedef typename std:: make_unsigned <T>::type |
Definition at line 28 of file type_mod.h.
using scl::tools::meta::mem_ptr_type = typedef Ret Class::* |
using scl::tools::meta::memfn_type = typedef Ret(Class::*)(Args...) |
using scl::tools::meta::no_op_t = typedef typename details::NoOp<T>::type |
Definition at line 48 of file type_mod.h.
using scl::tools::meta::real_const_t = typedef typename real_const<T>::type |
Definition at line 42 of file real_const.h.
using scl::tools::meta::remove_all_extents_t = typedef typename std:: remove_all_extents <T>::type |
Definition at line 31 of file type_mod.h.
using scl::tools::meta::remove_const_t = typedef typename std:: remove_const <T>::type |
Definition at line 13 of file type_mod.h.
using scl::tools::meta::remove_cv_ref_t = typedef remove_cv_t<remove_reference_t<T> > |
Definition at line 36 of file type_mod.h.
using scl::tools::meta::remove_cv_t = typedef typename std:: remove_cv <T>::type |
Definition at line 12 of file type_mod.h.
using scl::tools::meta::remove_extent_t = typedef typename std:: remove_extent <T>::type |
Definition at line 30 of file type_mod.h.
using scl::tools::meta::remove_pointer_t = typedef typename std:: remove_pointer <T>::type |
Definition at line 24 of file type_mod.h.
using scl::tools::meta::remove_reference_t = typedef typename std:: remove_reference <T>::type |
Definition at line 20 of file type_mod.h.
using scl::tools::meta::remove_volatile_t = typedef typename std:: remove_volatile <T>::type |
Definition at line 14 of file type_mod.h.
using scl::tools::meta::result_of_t = typedef typename std::result_of<Signature>::type |
Definition at line 45 of file type_query.h.
using scl::tools::meta::return_t = typedef typename function_traits<T>::return_type |
Definition at line 46 of file fn_introspect.h.
using scl::tools::meta::std_fn_type = typedef std::function<Ret(Args...)> |
Definition at line 86 of file fn_introspect.h.
using scl::tools::meta::tuple_element_t = typedef typename std::tuple_element<I, Tuple>::type |
Definition at line 38 of file type_query.h.
using scl::tools::meta::underlying_type_t = typedef typename std::underlying_type<T>::type |
Definition at line 35 of file type_query.h.
using scl::tools::meta::void_t = typedef void |
|
inline |
Definition at line 18 of file type_query.h.
std_fn_type<R(*)(Args...)> scl::tools::meta::as_fn | ( | R(*)(Args...) | f | ) |
Definition at line 89 of file fn_introspect.h.
std_fn_type<R(Class::* const)(Args...)> scl::tools::meta::as_fn | ( | R(Class::*)(Args...) const | f | ) |
Definition at line 94 of file fn_introspect.h.
Definition at line 100 of file fn_introspect.h.
|
inline |
Determines whether or not the given function can be called with the given argument types.
Func | being the type of the function (auto deduction) |
Args | being the arguments' types |
f | being the desired function |
Definition at line 30 of file can_call.h.
|
inline |
Definition at line 9 of file constexpr_assert.h.
|
inline |
Determines whether or not the operator<< is defined for the given type and ostream.
T | being the type to test upon |
Definition at line 30 of file defines_ostream_operator.h.
|
inline |
Determines whether or not ToString has been specialized for the given type.
T | being the type to test upon |
Definition at line 26 of file defines_scl_to_string.h.
|
inline |
Determines whether or not std::to_string(const T&) is defined.
T | being the type to test upon |
Definition at line 29 of file defines_std_to_string.h.
|
inline |
|
inline |
Definition at line 22 of file type_query.h.
|
inline |
Cast a function from its type to determined type.
From | being the actual type of the function |
Ret | being the new return type |
Args | being the new arguments' types |
f | being the function to cast |
|
inline |
Cast a member function from its type to determined type.
From | being the actual type of the function |
Class | being the new class it is from |
Ret | being the new return type |
Args | being the new arguments' types |
f | being the function to cast |
|
inline |
Definition at line 116 of file type_check.h.
|
inline |
Definition at line 72 of file type_check.h.
|
inline |
Definition at line 58 of file type_check.h.
|
inline |
Definition at line 46 of file type_check.h.
|
inline |
An handy function for the result of std::is_base_of.
Definition at line 12 of file is_base_of.h.
|
inline |
Definition at line 49 of file type_check.h.
|
inline |
Definition at line 61 of file type_check.h.
|
inline |
Definition at line 65 of file type_check.h.
|
inline |
Definition at line 89 of file type_check.h.
|
inline |
An handy function for the result of std::is_convertible.
Definition at line 17 of file is_convertible.h.
|
inline |
Definition at line 105 of file type_check.h.
|
inline |
Definition at line 97 of file type_check.h.
|
inline |
Determines whether or not a type defines copy semantics.
T | being the type to check against |
Definition at line 124 of file type_check.h.
|
inline |
Definition at line 93 of file type_check.h.
|
inline |
Definition at line 113 of file type_check.h.
|
inline |
Definition at line 70 of file type_check.h.
|
inline |
Definition at line 47 of file type_check.h.
|
inline |
Definition at line 45 of file type_check.h.
|
inline |
Definition at line 50 of file type_check.h.
|
inline |
Definition at line 57 of file type_check.h.
|
inline |
Determines whether a template type is an "instance" of a templated type.
U | being the templated type |
T | being the types composing the templated type (if the type to check is "instance") |
Definition at line 23 of file is_instance.h.
|
inline |
Definition at line 44 of file type_check.h.
|
inline |
Definition at line 160 of file type_check.h.
|
inline |
Definition at line 52 of file type_check.h.
|
inline |
Definition at line 55 of file type_check.h.
|
inline |
Definition at line 54 of file type_check.h.
|
inline |
Definition at line 63 of file type_check.h.
|
inline |
Determines whether or not a type defines move semantics.
T | being the type to check against |
Definition at line 134 of file type_check.h.
|
inline |
Definition at line 109 of file type_check.h.
|
inline |
Definition at line 101 of file type_check.h.
|
inline |
Definition at line 91 of file type_check.h.
|
inline |
Definition at line 107 of file type_check.h.
|
inline |
Definition at line 99 of file type_check.h.
|
inline |
Definition at line 95 of file type_check.h.
|
inline |
Definition at line 115 of file type_check.h.
|
inline |
Definition at line 111 of file type_check.h.
|
inline |
Definition at line 103 of file type_check.h.
|
inline |
Definition at line 43 of file type_check.h.
|
inline |
Definition at line 60 of file type_check.h.
|
inline |
Definition at line 51 of file type_check.h.
|
inline |
Definition at line 71 of file type_check.h.
|
inline |
Definition at line 62 of file type_check.h.
|
inline |
Definition at line 53 of file type_check.h.
|
inline |
|
inline |
Definition at line 59 of file type_check.h.
|
inline |
Definition at line 73 of file type_check.h.
|
inline |
Definition at line 69 of file type_check.h.
constexpr bool scl::tools::meta::is_swappable | ( | ) |
|
inline |
Definition at line 67 of file type_check.h.
|
inline |
Definition at line 90 of file type_check.h.
|
inline |
Definition at line 106 of file type_check.h.
|
inline |
Definition at line 98 of file type_check.h.
|
inline |
Definition at line 68 of file type_check.h.
|
inline |
Definition at line 94 of file type_check.h.
|
inline |
Definition at line 114 of file type_check.h.
|
inline |
Determines whether or not a type defines trivial move semantics.
T | being the type to check against |
Definition at line 144 of file type_check.h.
|
inline |
Definition at line 110 of file type_check.h.
|
inline |
Definition at line 102 of file type_check.h.
|
inline |
Definition at line 48 of file type_check.h.
|
inline |
Definition at line 74 of file type_check.h.
|
inline |
Definition at line 42 of file type_check.h.
|
inline |
Definition at line 66 of file type_check.h.
|
inline |
Definition at line 19 of file type_query.h.