Sacado Package Browser (Single Doxygen Collection)  Version of the Day
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Macros
Sacado_SFINAE_Macros.hpp File Reference
#include "Sacado_mpl_enable_if.hpp"
#include "Sacado_mpl_disable_if.hpp"
#include "Sacado_mpl_is_same.hpp"
#include "Sacado_mpl_is_convertible.hpp"
#include "Sacado_mpl_type_wrap.hpp"
Include dependency graph for Sacado_SFINAE_Macros.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define SACADO_ENABLE_IF_SAME(TYPE1, TYPE2, RETURN_TYPE)   typename mpl::enable_if_c<mpl::is_convertible< TYPE1 , TYPE2 >::value && ExprLevel<TYPE1>::value == ExprLevel<TYPE2>::value, RETURN_TYPE >::type
 
#define SACADO_ENABLE_EXPR_FUNC(RETURN_TYPE)   SACADO_ENABLE_IF_SAME(typename Expr<S>::value_type, value_type, RETURN_TYPE)
 
#define SACADO_ENABLE_EXPR_CTOR_DEF   SACADO_ENABLE_EXPR_FUNC(void*)
 
#define SACADO_ENABLE_EXPR_CTOR_DECL   SACADO_ENABLE_EXPR_CTOR_DEF = 0
 
#define SACADO_FAD_ENABLE_EXPR_FUNC   SACADO_ENABLE_IF_SAME(typename Expr<S>::value_type, typename FAD::value_type, FAD&)
 
#define SACADO_EXP_ENABLE_EXPR_FUNC(RETURN_TYPE)   SACADO_ENABLE_IF_SAME(typename Expr<S>::derived_type::value_type, value_type, RETURN_TYPE)
 
#define SACADO_EXP_ENABLE_EXPR_CTOR_DEF   SACADO_EXP_ENABLE_EXPR_FUNC(void*)
 
#define SACADO_EXP_ENABLE_EXPR_CTOR_DECL   SACADO_EXP_ENABLE_EXPR_CTOR_DEF = 0
 
#define SACADO_FAD_EXP_ENABLE_EXPR_FUNC   SACADO_ENABLE_IF_SAME(typename Expr<S>::derived_type::value_type, typename FAD::value_type, FAD&)
 
#define SACADO_ENABLE_IF_CONVERTIBLE(TYPE1, TYPE2, RETURN_TYPE)   typename Sacado::mpl::enable_if<Sacado::mpl::is_convertible< TYPE1 , TYPE2 >, RETURN_TYPE >::type
 
#define SACADO_ENABLE_VALUE_FUNC(RETURN_TYPE)   SACADO_ENABLE_IF_CONVERTIBLE(S, value_type, RETURN_TYPE)
 
#define SACADO_ENABLE_VALUE_CTOR_DEF   SACADO_ENABLE_VALUE_FUNC(void*)
 
#define SACADO_ENABLE_VALUE_CTOR_DECL   SACADO_ENABLE_VALUE_CTOR_DEF = 0
 
#define SACADO_FAD_OP_ENABLE_EXPR_EXPR(OP)
 
#define SACADO_FAD_EXP_OP_ENABLE_EXPR_EXPR(OP)
 
#define SACADO_FAD_OP_ENABLE_SCALAR_EXPR(OP)   typename mpl::disable_if<mpl::is_same< typename Expr<T>::value_type, typename Expr<T>::scalar_type>, Expr< OP< ConstExpr<typename Expr<T>::scalar_type>, Expr<T> > > >::type
 
#define SACADO_FAD_OP_ENABLE_EXPR_SCALAR(OP)   typename mpl::disable_if<mpl::is_same< typename Expr<T>::value_type, typename Expr<T>::scalar_type>, Expr< OP< Expr<T>, ConstExpr<typename Expr<T>::scalar_type> > > >::type
 
#define SACADO_FAD_EXP_OP_ENABLE_SCALAR_EXPR(OP)   typename mpl::disable_if<mpl::is_same< typename T::value_type, typename T::scalar_type>, OP< typename T::scalar_type, typename Expr<T>::derived_type, true, false, typename T::expr_spec_type > >::type
 
#define SACADO_FAD_EXP_OP_ENABLE_EXPR_SCALAR(OP)   typename mpl::disable_if<mpl::is_same< typename T::value_type, typename T::scalar_type>, OP< typename Expr<T>::derived_type, typename T::scalar_type, false, true, typename T::expr_spec_type > >::type
 

Macro Definition Documentation

#define SACADO_ENABLE_IF_SAME (   TYPE1,
  TYPE2,
  RETURN_TYPE 
)    typename mpl::enable_if_c<mpl::is_convertible< TYPE1 , TYPE2 >::value && ExprLevel<TYPE1>::value == ExprLevel<TYPE2>::value, RETURN_TYPE >::type

Definition at line 40 of file Sacado_SFINAE_Macros.hpp.

#define SACADO_ENABLE_EXPR_FUNC (   RETURN_TYPE)    SACADO_ENABLE_IF_SAME(typename Expr<S>::value_type, value_type, RETURN_TYPE)

Definition at line 42 of file Sacado_SFINAE_Macros.hpp.

#define SACADO_ENABLE_EXPR_CTOR_DEF   SACADO_ENABLE_EXPR_FUNC(void*)

Definition at line 44 of file Sacado_SFINAE_Macros.hpp.

#define SACADO_ENABLE_EXPR_CTOR_DECL   SACADO_ENABLE_EXPR_CTOR_DEF = 0

Definition at line 45 of file Sacado_SFINAE_Macros.hpp.

#define SACADO_FAD_ENABLE_EXPR_FUNC   SACADO_ENABLE_IF_SAME(typename Expr<S>::value_type, typename FAD::value_type, FAD&)

Definition at line 46 of file Sacado_SFINAE_Macros.hpp.

#define SACADO_EXP_ENABLE_EXPR_FUNC (   RETURN_TYPE)    SACADO_ENABLE_IF_SAME(typename Expr<S>::derived_type::value_type, value_type, RETURN_TYPE)

Definition at line 49 of file Sacado_SFINAE_Macros.hpp.

#define SACADO_EXP_ENABLE_EXPR_CTOR_DEF   SACADO_EXP_ENABLE_EXPR_FUNC(void*)

Definition at line 51 of file Sacado_SFINAE_Macros.hpp.

#define SACADO_EXP_ENABLE_EXPR_CTOR_DECL   SACADO_EXP_ENABLE_EXPR_CTOR_DEF = 0

Definition at line 52 of file Sacado_SFINAE_Macros.hpp.

#define SACADO_FAD_EXP_ENABLE_EXPR_FUNC   SACADO_ENABLE_IF_SAME(typename Expr<S>::derived_type::value_type, typename FAD::value_type, FAD&)

Definition at line 53 of file Sacado_SFINAE_Macros.hpp.

#define SACADO_ENABLE_IF_CONVERTIBLE (   TYPE1,
  TYPE2,
  RETURN_TYPE 
)    typename Sacado::mpl::enable_if<Sacado::mpl::is_convertible< TYPE1 , TYPE2 >, RETURN_TYPE >::type

Definition at line 56 of file Sacado_SFINAE_Macros.hpp.

#define SACADO_ENABLE_VALUE_FUNC (   RETURN_TYPE)    SACADO_ENABLE_IF_CONVERTIBLE(S, value_type, RETURN_TYPE)

Definition at line 58 of file Sacado_SFINAE_Macros.hpp.

#define SACADO_ENABLE_VALUE_CTOR_DEF   SACADO_ENABLE_VALUE_FUNC(void*)

Definition at line 60 of file Sacado_SFINAE_Macros.hpp.

#define SACADO_ENABLE_VALUE_CTOR_DECL   SACADO_ENABLE_VALUE_CTOR_DEF = 0

Definition at line 61 of file Sacado_SFINAE_Macros.hpp.

#define SACADO_FAD_OP_ENABLE_EXPR_EXPR (   OP)
Value:
typename mpl::enable_if_c< IsFadExpr<T1>::value && IsFadExpr<T2>::value && \
ExprLevel<T1>::value == ExprLevel<T2>::value, \
Expr< OP< T1, T2 > > \
>::type

Definition at line 63 of file Sacado_SFINAE_Macros.hpp.

#define SACADO_FAD_EXP_OP_ENABLE_EXPR_EXPR (   OP)
Value:
typename mpl::enable_if_c< IsFadExpr<T1>::value && IsFadExpr<T2>::value && \
ExprLevel<T1>::value == ExprLevel<T2>::value, \
OP< typename Expr<T1>::derived_type, typename Expr<T2>::derived_type, false, false, typename T1::expr_spec_type > \
>::type

Definition at line 68 of file Sacado_SFINAE_Macros.hpp.

#define SACADO_FAD_OP_ENABLE_SCALAR_EXPR (   OP)    typename mpl::disable_if<mpl::is_same< typename Expr<T>::value_type, typename Expr<T>::scalar_type>, Expr< OP< ConstExpr<typename Expr<T>::scalar_type>, Expr<T> > > >::type

Definition at line 73 of file Sacado_SFINAE_Macros.hpp.

#define SACADO_FAD_OP_ENABLE_EXPR_SCALAR (   OP)    typename mpl::disable_if<mpl::is_same< typename Expr<T>::value_type, typename Expr<T>::scalar_type>, Expr< OP< Expr<T>, ConstExpr<typename Expr<T>::scalar_type> > > >::type

Definition at line 75 of file Sacado_SFINAE_Macros.hpp.

#define SACADO_FAD_EXP_OP_ENABLE_SCALAR_EXPR (   OP)    typename mpl::disable_if<mpl::is_same< typename T::value_type, typename T::scalar_type>, OP< typename T::scalar_type, typename Expr<T>::derived_type, true, false, typename T::expr_spec_type > >::type

Definition at line 77 of file Sacado_SFINAE_Macros.hpp.

#define SACADO_FAD_EXP_OP_ENABLE_EXPR_SCALAR (   OP)    typename mpl::disable_if<mpl::is_same< typename T::value_type, typename T::scalar_type>, OP< typename Expr<T>::derived_type, typename T::scalar_type, false, true, typename T::expr_spec_type > >::type

Definition at line 79 of file Sacado_SFINAE_Macros.hpp.