IsUniform.h
Go to the documentation of this file.
1 //=================================================================================================
33 //=================================================================================================
34 
35 #ifndef _BLAZE_MATH_TYPETRAITS_ISUNIFORM_H_
36 #define _BLAZE_MATH_TYPETRAITS_ISUNIFORM_H_
37 
38 
39 //*************************************************************************************************
40 // Includes
41 //*************************************************************************************************
42 
45 #include <blaze/util/EnableIf.h>
46 #include <blaze/util/FalseType.h>
47 
48 
49 namespace blaze {
50 
51 //=================================================================================================
52 //
53 // CLASS DEFINITION
54 //
55 //=================================================================================================
56 
57 //*************************************************************************************************
59 template< typename T > struct IsUniform;
61 //*************************************************************************************************
62 
63 
64 //*************************************************************************************************
69 template< typename T
70  , typename = void >
71 struct IsUniformHelper
72  : public IsZero<T>
73 {};
74 
75 template< typename T > // Type of the operand
76 struct IsUniformHelper< T, EnableIf_t< IsExpression_v<T> > >
77  : public IsUniform< typename T::ResultType >::Type
78 {};
80 //*************************************************************************************************
81 
82 
83 //*************************************************************************************************
103 template< typename T >
104 struct IsUniform
105  : public IsUniformHelper<T>
106 {};
107 //*************************************************************************************************
108 
109 
110 //*************************************************************************************************
115 template< typename T >
116 struct IsUniform< const T >
117  : public IsUniform<T>
118 {};
120 //*************************************************************************************************
121 
122 
123 //*************************************************************************************************
128 template< typename T >
129 struct IsUniform< volatile T >
130  : public IsUniform<T>
131 {};
133 //*************************************************************************************************
134 
135 
136 //*************************************************************************************************
141 template< typename T >
142 struct IsUniform< const volatile T >
143  : public IsUniform<T>
144 {};
146 //*************************************************************************************************
147 
148 
149 //*************************************************************************************************
162 template< typename T >
164 //*************************************************************************************************
165 
166 } // namespace blaze
167 
168 #endif
Header file for the FalseType type/value trait base class.
Compile time check for uniform vectors and matrices.This type trait tests whether or not the given te...
Definition: IsUniform.h:104
typename EnableIf< Condition, T >::Type EnableIf_t
Auxiliary type for the EnableIf class template.The EnableIf_t alias declaration provides a convenient...
Definition: EnableIf.h:138
Namespace of the Blaze C++ math library.
Definition: Blaze.h:58
Header file for the EnableIf class template.
Header file for the IsZero type trait.
constexpr bool IsExpression_v
Auxiliary variable template for the IsExpression type trait.The IsExpression_v variable template prov...
Definition: IsExpression.h:131
constexpr bool IsUniform_v
Auxiliary variable template for the IsUniform type trait.The IsUniform_v variable template provides a...
Definition: IsUniform.h:163
Header file for the IsExpression type trait class.