]> git.tdb.fi Git - libs/core.git/blobdiff - source/core/meta.h
Deprecate various meta-programming constructs in favor of std ones
[libs/core.git] / source / core / meta.h
index 6998c5d1b8a712d69176a556e7c677bb745b9ec2..35373013e5eb91d6faceae24592dcd298f4b1280 100644 (file)
@@ -2,42 +2,46 @@
 #define MSP_CORE_META_H_
 
 #include <cstddef>
+#include "attributes.h"
 
 namespace Msp {
 
+#pragma GCC diagnostic push
+#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
 template<typename T>
-struct RemoveConst
+struct DEPRECATED RemoveConst
 { typedef T Type; };
 
 template<typename T>
-struct RemoveConst<const T>
+struct DEPRECATED RemoveConst<const T>
 { typedef T Type; };
 
 
 template<typename T>
-struct RemoveReference
+struct DEPRECATED RemoveReference
 { typedef T Type; };
 
 template<typename T>
-struct RemoveReference<T &>
+struct DEPRECATED RemoveReference<T &>
 { typedef T Type; };
 
 
 template<typename T>
-struct RemoveConstReference
+struct DEPRECATED RemoveConstReference
 { typedef typename RemoveConst<typename RemoveReference<T>::Type>::Type Type; };
 
 
 template<bool c, typename R>
-struct EnableIf;
+struct DEPRECATED EnableIf;
 
 template<typename R>
-struct EnableIf<true, R>
+struct DEPRECATED EnableIf<true, R>
 { typedef R Yes; };
 
 template<typename R>
-struct EnableIf<false, R>
+struct DEPRECATED EnableIf<false, R>
 { typedef R No; };
+#pragma GCC diagnostic pop
 
 
 /**