General Operator Detection#
- group General Operator Detection
Assortment of type traits to determine if an overload of an operator exists accepting one (or more) types.
Example:#
#include <hyperion/mpl/type_traits/is_operator_able.h> using namespace hyperion::mpl::type_traits; struct not_addable {}; static_assert(is_addable_v<int, int>); static_assert(!is_addable_v<not_addable, not_addable>);
Typedefs
-
template<typename TLhs>
using unary_plus_result_t = typename is_unary_plusable<TLhs>::result_type# Alias to the
result_typemembertypedefofis_unary_plusable. Used to determine the type of the returned result of invoking unaryoperator+on aTLhs, i.e.decltype(+std::declval<TLhs>())- Template Parameters:
TLhs – The type to check
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_unary_plusable<TLhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification of the unqualified type ofTLhs. I.E., given a typeTType, if you intend to invoke the unaryoperator+overload associated withTTypewith aconst TType&, make sure that you instantiate and useis_unary_plusablewithTLhs = const TType&, notTType,TType&or any other qualification.
-
template<typename TLhs>
using unary_minus_result_t = typename is_unary_minusable<TLhs>::result_type# Alias to the
result_typemembertypedefofis_unary_minusable. Used to determine the type of the returned result of invoking unaryoperator-on aTLhs, i.e.decltype(-std::declval<TLhs>())- Template Parameters:
TLhs – The type to check
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_unary_minusable<TLhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification of the unqualified type ofTLhs. I.E., given a typeTType, if you intend to invoke the unaryoperator-overload associated withTTypewith aconst TType&, make sure that you instantiate and useis_unary_minusablewithTLhs = const TType&, notTType,TType&or any other qualification.
-
template<typename TLhs>
using binary_not_result_t = typename is_binary_notable<TLhs>::result_type# Alias to the
result_typemembertypedefofis_binary_notable. Used to determine the type of the returned result of invokingoperator~on aTLhs, i.e.decltype(~std::declval<TLhs>())- Template Parameters:
TLhs – The type to check
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_binary_notable<TLhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification of the unqualified type ofTLhs. I.E., given a typeTType, if you intend to invoke the unaryoperator~overload associated withTTypewith aconst TType&, make sure that you instantiate and useis_binary_notablewithTLhs = const TType&, notTType,TType&or any other qualification.
-
template<typename TLhs>
using boolean_not_result_t = typename is_boolean_notable<TLhs>::result_type# Alias to the
result_typemembertypedefofis_boolean_notable. Used to determine the type of the returned result of invokingoperator!on aTLhs, i.e.decltype(!std::declval<TLhs>())- Template Parameters:
TLhs – The type to check
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_boolean_notable<TLhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification of the unqualified type ofTLhs. I.E., given a typeTType, if you intend to invoke the unaryoperator!overload associated withTTypewith aconst TType&, make sure that you instantiate and useis_boolean_notablewithTLhs = const TType&, notTType,TType&or any other qualification.
-
template<typename TLhs>
using address_result_t = typename is_addressable<TLhs>::result_type# Alias to the
result_typemembertypedefofis_addressable. Used to determine the type of the returned result of invoking unaryoperator&on aTLhs, i.e.decltype(&std::declval<TLhs>())- Template Parameters:
TLhs – The type to check
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_addressable<TLhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification of the unqualified type ofTLhs. I.E., given a typeTType, if you intend to invoke the unaryoperator&overload associated withTTypewith aconst TType&, make sure that you instantiate and useis_addressablewithTLhs = const TType&, notTType,TType&or any other qualification.
-
template<typename TLhs>
using arrow_result_t = typename is_arrowable<TLhs>::result_type# Alias to the
result_typemembertypedefofis_arrowable. Used to determine the type of the returned result of invokingoperator->on aTLhs, i.e.decltype(std::declval<TLhs>()->)- Template Parameters:
TLhs – The type to check
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_arrowable<TLhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification of the unqualified type ofTLhs. I.E., given a typeTType, if you intend to invoke theoperator->overload associated withTTypewith aconst TType&, make sure that you instantiate and useis_arrowablewithTLhs = const TType&, notTType,TType&or any other qualification.
-
template<typename TLhs>
using dereference_result_t = typename is_dereferencible<TLhs>::result_type# Alias to the
result_typemembertypedefofis_dereferencible. Used to determine the type of the returned result of invoking unaryoperator*on aTLhs, i.e.decltype(*std::declval<TLhs>())- Template Parameters:
TLhs – The type to check
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_dereferencible<TLhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification of the unqualified type ofTLhs. I.E., given a typeTType, if you intend to invoke the unaryoperator*overload associated withTTypewith aconst TType&, make sure that you instantiate and useis_dereferenciblewithTLhs = const TType&, notTType,TType&or any other qualification.
-
template<typename TLhs, typename TRhs = TLhs>
using add_result_t = typename is_addable<TLhs, TRhs>::result_type# Alias to the
result_typemembertypedefofis_addable. Used to determine the type of the returned result of invoking the addition operator (i.e.operator+) with aTLhsandTRhs, i.e.decltype(std::declval<TLhs>() + std::declval<TRhs>())- Template Parameters:
TLhs – The type of the left-hand parameter
TRhs – The type of the right-hand parameter. Defaults to
TLhs
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_addable<TLhs, TRhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification(s) of the unqualified types ofTLhsandTRhs. I.E., given typesTType1andTType2, if you intend to invoke the addition operator (i.e.operator+) overload associated withTType1andTType2withconst TType1&andconst TType2&, make sure sure that you instantiate and useis_addablewithTLhs = const TType1&andTRhs = const TType2&, notTType1,TType2&or any other qualification of either type thereof.
-
template<typename TLhs, typename TRhs = TLhs>
using subtract_result_t = typename is_subtractable<TLhs, TRhs>::result_type# Alias to the
result_typemembertypedefofis_subtractable. Used to determine the type of the returned result of invoking the subtraction operator (i.e.operator-) with aTLhsandTRhs, i.e.decltype(std::declval<TLhs>() - std::declval<TRhs>())- Template Parameters:
TLhs – The type of the left-hand parameter
TRhs – The type of the right-hand parameter. Defaults to
TLhs
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_subtractable<TLhs, TRhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification(s) of the unqualified types ofTLhsandTRhs. I.E., given typesTType1andTType2, if you intend to invoke the subtraction operator (i.e.operator-) overload associated withTType1andTType2withconst TType1&andconst TType2&, make sure sure that you instantiate and useis_subtractablewithTLhs = const TType1&andTRhs = const TType2&, notTType1,TType2&or any other qualification of either type thereof.
-
template<typename TLhs, typename TRhs = TLhs>
using multiply_result_t = typename is_multipliable<TLhs, TRhs>::result_type# Alias to the
result_typemembertypedefofis_multipliable. Used to determine the type of the returned result of invoking the multiplication operator (i.e.operator*) with aTLhsandTRhs, i.e.decltype(std::declval<TLhs>() * std::declval<TRhs>())- Template Parameters:
TLhs – The type of the left-hand parameter
TRhs – The type of the right-hand parameter. Defaults to
TLhs
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_multipliable<TLhs, TRhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification(s) of the unqualified types ofTLhsandTRhs. I.E., given typesTType1andTType2, if you intend to invoke the multiplication operator (i.e.operator*) overload associated withTType1andTType2withconst TType1&andconst TType2&, make sure sure that you instantiate and useis_multipliablewithTLhs = const TType1&andTRhs = const TType2&, notTType1,TType2&or any other qualification of either type thereof.
-
template<typename TLhs, typename TRhs = TLhs>
using divide_result_t = typename is_dividible<TLhs, TRhs>::result_type# Alias to the
result_typemembertypedefofis_dividible. Used to determine the type of the returned result of invoking the division operator (i.e.operator/) with aTLhsandTRhs, i.e.decltype(std::declval<TLhs>() / std::declval<TRhs>())- Template Parameters:
TLhs – The type of the left-hand parameter
TRhs – The type of the right-hand parameter. Defaults to
TLhs
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_dividible<TLhs, TRhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification(s) of the unqualified types ofTLhsandTRhs. I.E., given typesTType1andTType2, if you intend to invoke the division operator (i.e.operator/) overload associated withTType1andTType2withconst TType1&andconst TType2&, make sure sure that you instantiate and useis_dividiblewithTLhs = const TType1&andTRhs = const TType2&, notTType1,TType2&or any other qualification of either type thereof.
-
template<typename TLhs, typename TRhs = TLhs>
using binary_and_result_t = typename is_binary_andable<TLhs, TRhs>::result_type# Alias to the
result_typemembertypedefofis_binary_andable. Used to determine the type of the returned result of invoking the binary and operator (i.e.operator&) with aTLhsandTRhs, i.e.decltype(std::declval<TLhs>() & std::declval<TRhs>())- Template Parameters:
TLhs – The type of the left-hand parameter
TRhs – The type of the right-hand parameter. Defaults to
TLhs
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_binary_andable<TLhs, TRhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification(s) of the unqualified types ofTLhsandTRhs. I.E., given typesTType1andTType2, if you intend to invoke the binary and operator (i.e.operator&) overload associated withTType1andTType2withconst TType1&andconst TType2&, make sure sure that you instantiate and useis_binary_andablewithTLhs = const TType1&andTRhs = const TType2&, notTType1,TType2&or any other qualification of either type thereof.
-
template<typename TLhs, typename TRhs = TLhs>
using binary_or_result_t = typename is_binary_orable<TLhs, TRhs>::result_type# Alias to the
result_typemembertypedefofis_binary_orable. Used to determine the type of the returned result of invoking the binary or operator (i.e.operator|) with aTLhsandTRhs, i.e.decltype(std::declval<TLhs>() | std::declval<TRhs>())- Template Parameters:
TLhs – The type of the left-hand parameter
TRhs – The type of the right-hand parameter. Defaults to
TLhs
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_binary_orable<TLhs, TRhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification(s) of the unqualified types ofTLhsandTRhs. I.E., given typesTType1andTType2, if you intend to invoke the binary or operator (i.e.operator|) overload associated withTType1andTType2withconst TType1&andconst TType2&, make sure sure that you instantiate and useis_binary_orablewithTLhs = const TType1&andTRhs = const TType2&, notTType1,TType2&or any other qualification of either type thereof.
-
template<typename TLhs, typename TRhs = TLhs>
using boolean_and_result_t = typename is_boolean_andable<TLhs, TRhs>::result_type# Alias to the
result_typemembertypedefofis_boolean_andable. Used to determine the type of the returned result of invoking the boolean and operator (i.e.operator&&) with aTLhsandTRhs, i.e.decltype(std::declval<TLhs>() && std::declval<TRhs>())- Template Parameters:
TLhs – The type of the left-hand parameter
TRhs – The type of the right-hand parameter. Defaults to
TLhs
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_boolean_andable<TLhs, TRhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification(s) of the unqualified types ofTLhsandTRhs. I.E., given typesTType1andTType2, if you intend to invoke the boolean and operator (i.e.operator&&) overload associated withTType1andTType2withconst TType1&andconst TType2&, make sure sure that you instantiate and useis_boolean_andablewithTLhs = const TType1&andTRhs = const TType2&, notTType1,TType2&or any other qualification of either type thereof.
-
template<typename TLhs, typename TRhs = TLhs>
using boolean_or_result_t = typename is_boolean_orable<TLhs, TRhs>::result_type# Alias to the
result_typemembertypedefofis_boolean_orable. Used to determine the type of the returned result of invoking the boolean or operator (i.e.operator||) with aTLhsandTRhs, i.e.decltype(std::declval<TLhs>() || std::declval<TRhs>())- Template Parameters:
TLhs – The type of the left-hand parameter
TRhs – The type of the right-hand parameter. Defaults to
TLhs
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_boolean_orable<TLhs, TRhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification(s) of the unqualified types ofTLhsandTRhs. I.E., given typesTType1andTType2, if you intend to invoke the boolean or operator (i.e.operator||) overload associated withTType1andTType2withconst TType1&andconst TType2&, make sure sure that you instantiate and useis_boolean_orablewithTLhs = const TType1&andTRhs = const TType2&, notTType1,TType2&or any other qualification of either type thereof.
Variables
-
template<typename TLhs>
static auto is_unary_plusable_v = is_unary_plusable<TLhs>::value# Value of the type trait
is_unary_plusable. Used to determine if a type supports unaryoperator+.- Template Parameters:
TLhs – The type to check
Note
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification of the unqualified type ofTLhs. I.E., given a typeTType, if you intend to invoke the unaryoperator+overload associated withTTypewith aconst TType&, make sure that you instantiate and useis_unary_plusablewithTLhs = const TType&, notTType,TType&or any other qualification.
-
template<typename TLhs>
static auto is_unary_minusable_v = is_unary_minusable<TLhs>::value# Value of the type trait
is_unary_minusable. Used to determine if a type supports unaryoperator-.- Template Parameters:
TLhs – The type to check
Note
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification of the unqualified type ofTLhs. I.E., given a typeTType, if you intend to invoke the unaryoperator-overload associated withTTypewith aconst TType&, make sure that you instantiate and useis_unary_minusablewithTLhs = const TType&, notTType,TType&or any other qualification.
-
template<typename TLhs>
static auto is_binary_notable_v = is_binary_notable<TLhs>::value# Value of the type trait
is_binary_notable. Used to determine if a type supports the binary not operator, i.e.operator~.- Template Parameters:
TLhs – The type to check
Note
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification of the unqualified type ofTLhs. I.E., given a typeTType, if you intend to invoke the unaryoperator~overload associated withTTypewith aconst TType&, make sure that you instantiate and useis_binary_notablewithTLhs = const TType&, notTType,TType&or any other qualification.
-
template<typename TLhs>
static auto is_boolean_notable_v = is_boolean_notable<TLhs>::value# Value of the type trait
is_boolean_notable. Used to determine if a type supports the boolean not operator, i.e.operator!.- Template Parameters:
TLhs – The type to check
Note
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification of the unqualified type ofTLhs. I.E., given a typeTType, if you intend to invoke the unaryoperator!overload associated withTTypewith aconst TType&, make sure that you instantiate and useis_boolean_notablewithTLhs = const TType&, notTType,TType&or any other qualification.
-
template<typename TLhs>
static auto is_addressable_v = is_addressable<TLhs>::value# Value of the type trait
is_addressable. Used to determine if a type supports the address of operator, i.e. unaryoperator&.- Template Parameters:
TLhs – The type to check
Note
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification of the unqualified type ofTLhs. I.E., given a typeTType, if you intend to invoke the unaryoperator&overload associated withTTypewith aconst TType&, make sure that you instantiate and useis_addressablewithTLhs = const TType&, notTType,TType&or any other qualification.
-
template<typename TLhs>
static auto is_arrowable_v = is_arrowable<TLhs>::value# Value of the type trait
is_arrowable. Used to determine if a type supports the pointer to member operator, i.e.operator->.- Template Parameters:
TLhs – The type to check
Note
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification of the unqualified type ofTLhs. I.E., given a typeTType, if you intend to invoke theoperator->overload associated withTTypewith aconst TType&, make sure that you instantiate and useis_arrowablewithTLhs = const TType&, notTType,TType&or any other qualification.
-
template<typename TLhs>
static auto is_dereferencible_v = is_dereferencible<TLhs>::value# Value of the type trait
is_dereferencible. Used to determine if a type supports the dereference operator, i.e. unaryoperator*.- Template Parameters:
TLhs – The type to check
Note
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification of the unqualified type ofTLhs. I.E., given a typeTType, if you intend to invoke the unaryoperator*overload associated withTTypewith aconst TType&, make sure that you instantiate and useis_dereferenciblewithTLhs = const TType&, notTType,TType&or any other qualification.
-
template<typename TLhs, typename TRhs = TLhs>
static auto is_addable_v = is_addable<TLhs, TRhs>::value# Value of the type trait
is_addable. Used to determine ifTLhsandTRhsare addable.- Template Parameters:
TLhs – The type of the left-hand parameter
TRhs – The type of the right-hand parameter. Defaults to
TLhs
Note
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification(s) of the unqualified types ofTLhsandTRhs. I.E., given typesTType1andTType2, if you intend to invoke the addition operator (i.e.operator+) overload associated withTType1andTType2withconst TType1&andconst TType2&, make sure sure that you instantiate and useis_addablewithTLhs = const TType1&andTRhs = const TType2&, notTType1,TType2&or any other qualification of either type thereof.
-
template<typename TLhs, typename TRhs = TLhs>
static auto is_subtractable_v = is_subtractable<TLhs, TRhs>::value# Value of the type trait
is_subtractable. Used to determine ifTLhsandTRhsare subtractable.- Template Parameters:
TLhs – The type of the left-hand parameter
TRhs – The type of the right-hand parameter. Defaults to
TLhs
Note
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification(s) of the unqualified types ofTLhsandTRhs. I.E., given typesTType1andTType2, if you intend to invoke the subtraction operator (i.e.operator-) overload associated withTType1andTType2withconst TType1&andconst TType2&, make sure sure that you instantiate and useis_subtractablewithTLhs = const TType1&andTRhs = const TType2&, notTType1,TType2&or any other qualification of either type thereof.
-
template<typename TLhs, typename TRhs = TLhs>
static auto is_multipliable_v = is_multipliable<TLhs, TRhs>::value# Value of the type trait
is_multipliable. Used to determine ifTLhsandTRhsare multipliable.- Template Parameters:
TLhs – The type of the left-hand parameter
TRhs – The type of the right-hand parameter. Defaults to
TLhs
Note
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification(s) of the unqualified types ofTLhsandTRhs. I.E., given typesTType1andTType2, if you intend to invoke the multiplication operator (i.e.operator*) overload associated withTType1andTType2withconst TType1&andconst TType2&, make sure sure that you instantiate and useis_multipliablewithTLhs = const TType1&andTRhs = const TType2&, notTType1,TType2&or any other qualification of either type thereof.
-
template<typename TLhs, typename TRhs = TLhs>
static auto is_dividible_v = is_dividible<TLhs, TRhs>::value# Value of the type trait
is_dividible. Used to determine ifTLhsandTRhsare dividible.- Template Parameters:
TLhs – The type of the left-hand parameter
TRhs – The type of the right-hand parameter. Defaults to
TLhs
Note
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification(s) of the unqualified types ofTLhsandTRhs. I.E., given typesTType1andTType2, if you intend to invoke the division operator (i.e.operator/) overload associated withTType1andTType2withconst TType1&andconst TType2&, make sure sure that you instantiate and useis_dividiblewithTLhs = const TType1&andTRhs = const TType2&, notTType1,TType2&or any other qualification of either type thereof.
-
template<typename TLhs, typename TRhs = TLhs>
static auto is_binary_andable_v = is_binary_andable<TLhs, TRhs>::value# Value of the type trait
is_binary_andable. Used to determine ifTLhsandTRhsare binary andable.- Template Parameters:
TLhs – The type of the left-hand parameter
TRhs – The type of the right-hand parameter. Defaults to
TLhs
Note
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification(s) of the unqualified types ofTLhsandTRhs. I.E., given typesTType1andTType2, if you intend to invoke the binary and operator (i.e.operator&) overload associated withTType1andTType2withconst TType1&andconst TType2&, make sure sure that you instantiate and useis_binary_andablewithTLhs = const TType1&andTRhs = const TType2&, notTType1,TType2&or any other qualification of either type thereof.
-
template<typename TLhs, typename TRhs = TLhs>
static auto is_binary_orable_v = is_binary_orable<TLhs, TRhs>::value# Value of the type trait
is_binary_orable. Used to determine ifTLhsandTRhsare binary orable.- Template Parameters:
TLhs – The type of the left-hand parameter
TRhs – The type of the right-hand parameter. Defaults to
TLhs
Note
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification(s) of the unqualified types ofTLhsandTRhs. I.E., given typesTType1andTType2, if you intend to invoke the binary or operator (i.e.operator|) overload associated withTType1andTType2withconst TType1&andconst TType2&, make sure sure that you instantiate and useis_binary_orablewithTLhs = const TType1&andTRhs = const TType2&, notTType1,TType2&or any other qualification of either type thereof.
-
template<typename TLhs, typename TRhs = TLhs>
static auto is_boolean_andable_v = is_boolean_andable<TLhs, TRhs>::value# Value of the type trait
is_boolean_andable. Used to determine ifTLhsandTRhsare boolean andable.- Template Parameters:
TLhs – The type of the left-hand parameter
TRhs – The type of the right-hand parameter. Defaults to
TLhs
Note
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification(s) of the unqualified types ofTLhsandTRhs. I.E., given typesTType1andTType2, if you intend to invoke the boolean and operator (i.e.operator&&) overload associated withTType1andTType2withconst TType1&andconst TType2&, make sure sure that you instantiate and useis_boolean_andablewithTLhs = const TType1&andTRhs = const TType2&, notTType1,TType2&or any other qualification of either type thereof.
-
template<typename TLhs, typename TRhs = TLhs>
static auto is_boolean_orable_v = is_boolean_orable<TLhs, TRhs>::value# Value of the type trait
is_boolean_orable. Used to determine ifTLhsandTRhsare boolean orable.- Template Parameters:
TLhs – The type of the left-hand parameter
TRhs – The type of the right-hand parameter. Defaults to
TLhs
Note
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification(s) of the unqualified types ofTLhsandTRhs. I.E., given typesTType1andTType2, if you intend to invoke the boolean or operator (i.e.operator||) overload associated withTType1andTType2withconst TType1&andconst TType2&, make sure sure that you instantiate and useis_boolean_orablewithTLhs = const TType1&andTRhs = const TType2&, notTType1,TType2&or any other qualification of either type thereof.
-
template<typename TLhs>
struct is_unary_plusable : public std::false_type# - #include <hyperion/mpl/type_traits/is_operator_able.h>
Type Trait to determine if a type supports unary
operator+.In addition to providing the static member
value, indicating whether aTLhssupports unaryoperator+, also provides the membertypedeftyperesult_typeequal to the type of the returned result of invoking the associatedoperator+overload, i.e.decltype(+std::declval<TLhs>())- Template Parameters:
TLhs – The type to check
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_unary_plusable<TLhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification of the unqualified type ofTLhs. I.E., given a typeTType, if you intend to invoke the unaryoperator+overload associated withTTypewith aconst TType&, make sure that you instantiate and useis_unary_plusablewithTLhs = const TType&, notTType,TType&or any other qualification.
-
template<typename TLhs>
struct is_unary_minusable : public std::false_type# - #include <hyperion/mpl/type_traits/is_operator_able.h>
Type Trait to determine if a type supports unary
operator-.In addition to providing the static member
value, indicating whether aTLhssupports unaryoperator-, also provides the membertypedeftyperesult_typeequal to the type of the returned result of invoking the associatedoperator-overload, i.e.decltype(-std::declval<TLhs>())- Template Parameters:
TLhs – The type to check
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_unary_minusable<TLhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification of the unqualified type ofTLhs. I.E., given a typeTType, if you intend to invoke the unaryoperator-overload associated withTTypewith aconst TType&, make sure that you instantiate and useis_unary_minusablewithTLhs = const TType&, notTType,TType&or any other qualification.
-
template<typename TLhs>
struct is_binary_notable : public std::false_type# - #include <hyperion/mpl/type_traits/is_operator_able.h>
Type Trait to determine if a type supports the binary not operator, i.e.
operator~.In addition to providing the static member
value, indicating whether aTLhssupportsoperator~, also provides the membertypedeftyperesult_typeequal to the type of the returned result of invoking the associatedoperator~overload, i.e.decltype(~std::declval<TLhs>())- Template Parameters:
TLhs – The type to check
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_binary_notable<TLhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification of the unqualified type ofTLhs. I.E., given a typeTType, if you intend to invoke the unaryoperator~overload associated withTTypewith aconst TType&, make sure that you instantiate and useis_binary_notablewithTLhs = const TType&, notTType,TType&or any other qualification.
-
template<typename TLhs>
struct is_boolean_notable : public std::false_type# - #include <hyperion/mpl/type_traits/is_operator_able.h>
Type Trait to determine if a type supports the boolean not operator, i.e.
operator!.In addition to providing the static member
value, indicating whether aTLhssupportsoperator!, also provides the membertypedeftyperesult_typeequal to the type of the returned result of invoking the associatedoperator!overload, i.e.decltype(!std::declval<TLhs>())- Template Parameters:
TLhs – The type to check
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_boolean_notable<TLhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification of the unqualified type ofTLhs. I.E., given a typeTType, if you intend to invoke the unaryoperator!overload associated withTTypewith aconst TType&, make sure that you instantiate and useis_boolean_notablewithTLhs = const TType&, notTType,TType&or any other qualification.
-
template<typename TLhs>
struct is_addressable : public std::false_type# - #include <hyperion/mpl/type_traits/is_operator_able.h>
Type Trait to determine if a type supports the address of operator, i.e. unary
operator&.In addition to providing the static member
value, indicating whether aTLhssupports unaryoperator&, also provides the membertypedeftyperesult_typeequal to the type of the returned result of invoking the associatedoperator&overload, i.e.decltype(&std::declval<TLhs>())- Template Parameters:
TLhs – The type to check
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_addressable<TLhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification of the unqualified type ofTLhs. I.E., given a typeTType, if you intend to invoke the unaryoperator&overload associated withTTypewith aconst TType&, make sure that you instantiate and useis_addressablewithTLhs = const TType&, notTType,TType&or any other qualification.
-
template<typename TLhs>
struct is_arrowable : public std::false_type# - #include <hyperion/mpl/type_traits/is_operator_able.h>
Type Trait to determine if a type supports the pointer to member operator, i.e.
operator->.In addition to providing the static member
value, indicating whether aTLhssupportsoperator->, also provides the membertypedeftyperesult_typeequal to the type of the returned result of invoking the associatedoperator->overload, i.e.decltype(std::declval<TLhs>()->)- Template Parameters:
TLhs – The type to check
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_arrowable<TLhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification of the unqualified type ofTLhs. I.E., given a typeTType, if you intend to invoke theoperator->overload associated withTTypewith aconst TType&, make sure that you instantiate and useis_arrowablewithTLhs = const TType&, notTType,TType&or any other qualification.
-
template<typename TLhs>
struct is_dereferencible : public std::false_type# - #include <hyperion/mpl/type_traits/is_operator_able.h>
Type Trait to determine if a type supports the dereference operator, i.e. unary
operator*.In addition to providing the static member
value, indicating whether aTLhssupports unaryoperator*, also provides the membertypedeftyperesult_typeequal to the type of the returned result of invoking the associatedoperator*overload, i.e.decltype(*std::declval<TLhs>())- Template Parameters:
TLhs – The type to check
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_dereferencible<TLhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification of the unqualified type ofTLhs. I.E., given a typeTType, if you intend to invoke the unaryoperator*overload associated withTTypewith aconst TType&, make sure that you instantiate and useis_dereferenciblewithTLhs = const TType&, notTType,TType&or any other qualification.
-
template<typename TLhs, typename TRhs = TLhs>
struct is_addable : public std::false_type# - #include <hyperion/mpl/type_traits/is_operator_able.h>
Type trait to determine if
TLhsandTRhsare addable.In addition to providing the static member
value, indicating whether aTLhsandTRhsare addable, also provides the membertypedeftyperesult_typeequal to the type of the returned result of invoking the associatedoperator+overload, i.e.decltype(std::declval<TLhs>() + std::declval<TRhs>()).- Template Parameters:
TLhs – The type of the left-hand parameter
TRhs – The type of the right-hand parameter. Defaults to
TLhs
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_addable<TLhs, TRhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification(s) of the unqualified types ofTLhsandTRhs. I.E., given typesTType1andTType2, if you intend to invoke the addition operator (i.e.operator+) overload associated withTType1andTType2withconst TType1&andconst TType2&, make sure sure that you instantiate and useis_addablewithTLhs = const TType1&andTRhs = const TType2&, notTType1,TType2&or any other qualification of either type thereof.
-
template<typename TLhs, typename TRhs = TLhs>
struct is_subtractable : public std::false_type# - #include <hyperion/mpl/type_traits/is_operator_able.h>
Type trait to determine if
TLhsandTRhsare subtractable.In addition to providing the static member
value, indicating whether aTLhsandTRhsare subtractable, also provides the membertypedeftyperesult_typeequal to the type of the returned result of invoking the associatedoperator-overload, i.e.decltype(std::declval<TLhs>() - std::declval<TRhs>()).- Template Parameters:
TLhs – The type of the left-hand parameter
TRhs – The type of the right-hand parameter. Defaults to
TLhs
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_subtractable<TLhs, TRhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification(s) of the unqualified types ofTLhsandTRhs. I.E., given typesTType1andTType2, if you intend to invoke the subtraction operator (i.e.operator-) overload associated withTType1andTType2withconst TType1&andconst TType2&, make sure sure that you instantiate and useis_subtractablewithTLhs = const TType1&andTRhs = const TType2&, notTType1,TType2&or any other qualification of either type thereof.
-
template<typename TLhs, typename TRhs = TLhs>
struct is_multipliable : public std::false_type# - #include <hyperion/mpl/type_traits/is_operator_able.h>
Type trait to determine if
TLhsandTRhsare multipliable.In addition to providing the static member
value, indicating whether aTLhsandTRhsare multipliable, also provides the membertypedeftyperesult_typeequal to the type of the returned result of invoking the associatedoperator*overload, i.e.decltype(std::declval<TLhs>() * std::declval<TRhs>()).- Template Parameters:
TLhs – The type of the left-hand parameter
TRhs – The type of the right-hand parameter. Defaults to
TLhs
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_multipliable<TLhs, TRhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification(s) of the unqualified types ofTLhsandTRhs. I.E., given typesTType1andTType2, if you intend to invoke the multiplication operator (i.e.operator*) overload associated withTType1andTType2withconst TType1&andconst TType2&, make sure sure that you instantiate and useis_multipliablewithTLhs = const TType1&andTRhs = const TType2&, notTType1,TType2&or any other qualification of either type thereof.
-
template<typename TLhs, typename TRhs = TLhs>
struct is_dividible : public std::false_type# - #include <hyperion/mpl/type_traits/is_operator_able.h>
Type trait to determine if
TLhsandTRhsare dividible.In addition to providing the static member
value, indicating whether aTLhsandTRhsare dividible, also provides the membertypedeftyperesult_typeequal to the type of the returned result of invoking the associatedoperator/overload, i.e.decltype(std::declval<TLhs>() / std::declval<TRhs>()).- Template Parameters:
TLhs – The type of the left-hand parameter
TRhs – The type of the right-hand parameter. Defaults to
TLhs
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_dividible<TLhs, TRhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification(s) of the unqualified types ofTLhsandTRhs. I.E., given typesTType1andTType2, if you intend to invoke the division operator (i.e.operator/) overload associated withTType1andTType2withconst TType1&andconst TType2&, make sure sure that you instantiate and useis_dividiblewithTLhs = const TType1&andTRhs = const TType2&, notTType1,TType2&or any other qualification of either type thereof.
-
template<typename TLhs, typename TRhs = TLhs>
struct is_binary_andable : public std::false_type# - #include <hyperion/mpl/type_traits/is_operator_able.h>
Type trait to determine if
TLhsandTRhsare binary andable.In addition to providing the static member
value, indicating whether aTLhsandTRhsare binary andable, also provides the membertypedeftyperesult_typeequal to the type of the returned result of invoking the associatedoperator&overload, i.e.decltype(std::declval<TLhs>() & std::declval<TRhs>()).- Template Parameters:
TLhs – The type of the left-hand parameter
TRhs – The type of the right-hand parameter. Defaults to
TLhs
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_binary_andable<TLhs, TRhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification(s) of the unqualified types ofTLhsandTRhs. I.E., given typesTType1andTType2, if you intend to invoke the binary and operator (i.e.operator&) overload associated withTType1andTType2withconst TType1&andconst TType2&, make sure sure that you instantiate and useis_binary_andablewithTLhs = const TType1&andTRhs = const TType2&, notTType1,TType2&or any other qualification of either type thereof.
-
template<typename TLhs, typename TRhs = TLhs>
struct is_binary_orable : public std::false_type# - #include <hyperion/mpl/type_traits/is_operator_able.h>
Type trait to determine if
TLhsandTRhsare binary orable.In addition to providing the static member
value, indicating whether aTLhsandTRhsare binary orable, also provides the membertypedeftyperesult_typeequal to the type of the returned result of invoking the associatedoperator|overload, i.e.decltype(std::declval<TLhs>() | std::declval<TRhs>()).- Template Parameters:
TLhs – The type of the left-hand parameter
TRhs – The type of the right-hand parameter. Defaults to
TLhs
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_binary_orable<TLhs, TRhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification(s) of the unqualified types ofTLhsandTRhs. I.E., given typesTType1andTType2, if you intend to invoke the binary or operator (i.e.operator|) overload associated withTType1andTType2withconst TType1&andconst TType2&, make sure sure that you instantiate and useis_binary_orablewithTLhs = const TType1&andTRhs = const TType2&, notTType1,TType2&or any other qualification of either type thereof.
-
template<typename TLhs, typename TRhs = TLhs>
struct is_boolean_andable : public std::false_type# - #include <hyperion/mpl/type_traits/is_operator_able.h>
Type trait to determine if
TLhsandTRhsare boolean andable.In addition to providing the static member
value, indicating whether aTLhsandTRhsare boolean andable, also provides the membertypedeftyperesult_typeequal to the type of the returned result of invoking the associatedoperator&&overload, i.e.decltype(std::declval<TLhs>() && std::declval<TRhs>()).- Template Parameters:
TLhs – The type of the left-hand parameter
TRhs – The type of the right-hand parameter. Defaults to
TLhs
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_boolean_andable<TLhs, TRhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification(s) of the unqualified types ofTLhsandTRhs. I.E., given typesTType1andTType2, if you intend to invoke the boolean and operator (i.e.operator&&) overload associated withTType1andTType2withconst TType1&andconst TType2&, make sure sure that you instantiate and useis_boolean_andablewithTLhs = const TType1&andTRhs = const TType2&, notTType1,TType2&or any other qualification of either type thereof.
-
template<typename TLhs, typename TRhs = TLhs>
struct is_boolean_orable : public std::false_type# - #include <hyperion/mpl/type_traits/is_operator_able.h>
Type trait to determine if
TLhsandTRhsare boolean orable.In addition to providing the static member
value, indicating whether aTLhsandTRhsare boolean orable, also provides the membertypedeftyperesult_typeequal to the type of the returned result of invoking the associatedoperator||overload, i.e.decltype(std::declval<TLhs>() || std::declval<TRhs>()).- Template Parameters:
TLhs – The type of the left-hand parameter
TRhs – The type of the right-hand parameter. Defaults to
TLhs
Note
Presence of
result_typeshould not be used as a short-hand or alternaitve to checkingvaluein any way (e.g. in a SFINAE-compatible context or C++20requiresclause): ifis_boolean_orable<TLhs, TRhs>::value == false, thenresult_typewill bevoidNote
Due to overloadability by cv-ref qualification, care should be taken to ensure that use of
result_type(and this trait in general) is associated with the correct cv-ref qualification(s) of the unqualified types ofTLhsandTRhs. I.E., given typesTType1andTType2, if you intend to invoke the boolean or operator (i.e.operator||) overload associated withTType1andTType2withconst TType1&andconst TType2&, make sure sure that you instantiate and useis_boolean_orablewithTLhs = const TType1&andTRhs = const TType2&, notTType1,TType2&or any other qualification of either type thereof.
-
template<typename TLhs>