blaze
util
constraints
Subscriptable.h
Go to the documentation of this file.
1
//=================================================================================================
33
//=================================================================================================
34
35
#ifndef _BLAZE_UTIL_CONSTRAINTS_SUBSCRIPTABLE_H_
36
#define _BLAZE_UTIL_CONSTRAINTS_SUBSCRIPTABLE_H_
37
38
39
//*************************************************************************************************
40
// Includes
41
//*************************************************************************************************
42
43
#include <utility>
44
45
46
namespace
blaze
{
47
48
//=================================================================================================
49
//
50
// MUST_BE_SUBSCRIBTABLE CONSTRAINT
51
//
52
//=================================================================================================
53
54
//*************************************************************************************************
60
#define BLAZE_CONSTRAINT_MUST_BE_SUBSCRIPTABLE(T) \
61
static_assert( sizeof( std::declval<T>()[0] ) > 0UL, "Non-subscriptable type detected" )
62
//*************************************************************************************************
63
64
65
66
67
//=================================================================================================
68
//
69
// MUST_BE_SUBSCRIBTABLE_AS_DECAYABLE_POINTER CONSTRAINT
70
//
71
//=================================================================================================
72
73
//*************************************************************************************************
79
#define BLAZE_CONSTRAINT_MUST_BE_SUBSCRIPTABLE_AS_DECAYABLE_POINTER(T) \
80
static_assert( sizeof( 0[std::declval<T>()] ) > 0UL, "Non-subscriptable pointer detected" )
81
//*************************************************************************************************
82
83
}
// namespace blaze
84
85
#endif
blaze
Namespace of the Blaze C++ math library.
Definition:
Blaze.h:58
Generated on Sun Feb 11 2018 05:34:02 by
1.8.13