16#ifndef dealii_template_constraints_h
17#define dealii_template_constraints_h
32 namespace TemplateConstraints
35 template <
bool... Values>
43 template <
bool... Values>
59template <
class Base,
class... Derived>
63 std::is_base_of<Base, Derived>::value...>
::value;
74template <
class Type,
class... Types>
78 std::is_same<Type, Types>::value...>
::value;
88template <
bool... Values>
90 : std::enable_if<internal::TemplateConstraints::all_true<Values...>::value>
103 template <
typename C>
104 static std::false_type
107 template <
typename C>
114 using type =
decltype(test<T>(0));
116 static const bool value = type::value;
191template <
typename ArgType,
typename ValueType>
226 template <
typename T>
240 template <
typename T,
typename U>
262 template <
typename T,
typename U>
265 using type =
decltype(std::declval<T>() * std::declval<U>());
318template <
typename T,
typename U>
323 typename std::decay<U>::type>
::type;
333 template <
typename T>
339 template <
typename T,
typename U>
342 using type = std::complex<typename ProductType<T, U>::type>;
345 template <
typename U>
348 using type = std::complex<typename ProductType<double, U>::type>;
351 template <
typename T>
354 using type = std::complex<typename ProductType<T, double>::type>;
357 template <
typename U>
360 using type = std::complex<typename ProductType<float, U>::type>;
363 template <
typename T>
366 using type = std::complex<typename ProductType<T, float>::type>;
static std::false_type test(...)
decltype(test< T >(0)) type
static auto test(int) -> decltype(std::begin(std::declval< C >()), std::end(std::declval< C >()), std::true_type())
#define DEAL_II_NAMESPACE_OPEN
#define DEAL_II_NAMESPACE_CLOSE
VectorType::value_type * end(VectorType &V)
VectorType::value_type * begin(VectorType &V)
static bool equal(const T *p1, const T *p2)
static bool equal(const T *, const U *)
typename internal::ProductTypeImpl< typename std::decay< T >::type, typename std::decay< U >::type >::type type
static constexpr bool value
ValueType operator()(const ArgType &)
std::complex< typename ProductType< double, U >::type > type
std::complex< typename ProductType< float, U >::type > type
std::complex< typename ProductType< T, double >::type > type
std::complex< typename ProductType< T, float >::type > type
std::complex< typename ProductType< T, U >::type > type
decltype(std::declval< T >() *std::declval< U >()) type
static constexpr bool value
static constexpr bool value