Blaze 3.9
IsShrinkable.h
Go to the documentation of this file.
1//=================================================================================================
33//=================================================================================================
34
35#ifndef _BLAZE_MATH_TYPETRAITS_ISSHRINKABLE_H_
36#define _BLAZE_MATH_TYPETRAITS_ISSHRINKABLE_H_
37
38
39//*************************************************************************************************
40// Includes
41//*************************************************************************************************
42
43#include <utility>
47
48
49namespace blaze {
50
51//=================================================================================================
52//
53// CLASS DEFINITION
54//
55//=================================================================================================
56
57//*************************************************************************************************
62template< typename T >
63using ShrinkToFit_t = decltype( std::declval<T&>().shrinkToFit() );
65//*************************************************************************************************
66
67
68//*************************************************************************************************
87template< typename T >
89 : public IsDetected< ShrinkToFit_t, RemoveAdaptor_t<T> >
90{};
91//*************************************************************************************************
92
93
94//*************************************************************************************************
99template< typename T >
100struct IsShrinkable<T&>
101 : public FalseType
102{};
104//*************************************************************************************************
105
106
107//*************************************************************************************************
120template< typename T >
122//*************************************************************************************************
123
124} // namespace blaze
125
126#endif
Header file for the IntegralConstant class template.
Header file for the IsDetected type trait.
Header file for the RemoveAdaptor type trait.
constexpr bool IsShrinkable_v
Auxiliary variable template for the IsShrinkable type trait.
Definition: IsShrinkable.h:121
typename DetectedOr< NoneSuch, OP, Ts... >::Value_t IsDetected
Compile time detection of type properties.
Definition: IsDetected.h:151
Generic wrapper for a compile time constant integral value.
Definition: IntegralConstant.h:74
Compile time check for shrinkable data types.
Definition: IsShrinkable.h:90