Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r81176 - in trunk: boost/tti boost/tti/detail boost/tti/gen libs/tti/doc libs/tti/test
From: eldiener_at_[hidden]
Date: 2012-11-04 19:18:18


Author: eldiener
Date: 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
New Revision: 81176
URL: http://svn.boost.org/trac/boost/changeset/81176

Log:
Updates to BOOST_TTI_TEMPLATE and documentation.
Added:
   trunk/boost/tti/detail/dtemplate.hpp (contents, props changed)
Removed:
   trunk/libs/tti/doc/TypeTraitsIntrospection.pdf
Text files modified:
   trunk/boost/tti/detail/dtemplate_params.hpp | 64 ++++++-
   trunk/boost/tti/detail/dvm_template_params.hpp | 111 ++++++++++++
   trunk/boost/tti/gen/has_template_check_params_gen.hpp | 4
   trunk/boost/tti/gen/vm_has_template_check_params_gen.hpp | 3
   trunk/boost/tti/has_template.hpp | 82 ++++++++
   trunk/boost/tti/has_template_check_params.hpp | 5
   trunk/boost/tti/vm_has_template_check_params.hpp | 3
   trunk/libs/tti/doc/tti.qbk | 1
   trunk/libs/tti/doc/tti_detail.qbk | 32 ++-
   trunk/libs/tti/doc/tti_detail_has_template.qbk | 210 +++++++++++++++++++++++-
   trunk/libs/tti/doc/tti_detail_has_template_check_params.qbk | 8
   trunk/libs/tti/doc/tti_functionality.qbk | 10
   trunk/libs/tti/doc/tti_introduction.qbk | 92 +++++++---
   trunk/libs/tti/doc/tti_terminology.qbk | 3
   trunk/libs/tti/test/Jamfile.v2 | 347 +++++++++++++++++++++++++++++++++------
   trunk/libs/tti/test/test_has_template.hpp | 30 +++
   trunk/libs/tti/test/test_has_template_cp.cpp | 19 +
   trunk/libs/tti/test/test_has_template_cp.hpp | 20 ++
   trunk/libs/tti/test/test_has_template_cp_compile.cpp | 24 ++
   trunk/libs/tti/test/test_has_template_cp_fail.cpp | 11 +
   trunk/libs/tti/test/test_vm_has_template_cp.cpp | 19 +
   trunk/libs/tti/test/test_vm_has_template_cp.hpp | 20 ++
   trunk/libs/tti/test/test_vm_has_template_cp_compile.cpp | 24 ++
   trunk/libs/tti/test/test_vm_has_template_cp_fail.cpp | 10 +
   24 files changed, 1005 insertions(+), 147 deletions(-)

Added: trunk/boost/tti/detail/dtemplate.hpp
==============================================================================
--- (empty file)
+++ trunk/boost/tti/detail/dtemplate.hpp 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -0,0 +1,51 @@
+
+// (C) Copyright Edward Diener 2011
+// Use, modification and distribution are subject to the Boost Software License,
+// Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
+// http://www.boost.org/LICENSE_1_0.txt).
+
+#if !defined(TTI_DETAIL_TEMPLATE_HPP)
+#define TTI_DETAIL_TEMPLATE_HPP
+
+#if defined(BOOST_TTI_VERSION_1_6)
+
+#include <boost/config.hpp>
+#include <boost/mpl/has_xxx.hpp>
+#include <boost/preprocessor/cat.hpp>
+#include <boost/preprocessor/debug/assert.hpp>
+#include <boost/preprocessor/facilities/is_empty.hpp>
+
+#define TTI_DETAIL_IS_HELPER_BOOST_PP_NIL
+
+#define TTI_DETAIL_IS_NIL(param) \
+ BOOST_PP_IS_EMPTY \
+ ( \
+ BOOST_PP_CAT(TTI_DETAIL_IS_HELPER_,param) \
+ ) \
+/**/
+
+#define TTI_DETAIL_TRAIT_ASSERT_NOT_NIL(trait,name,params) \
+ BOOST_PP_ASSERT_MSG(0, "The parameter must be BOOST_PP_NIL") \
+/**/
+
+#define TTI_DETAIL_TRAIT_CHECK_IS_NIL(trait,name,params) \
+ BOOST_PP_IIF \
+ ( \
+ TTI_DETAIL_IS_NIL(params), \
+ TTI_DETAIL_TRAIT_HAS_TEMPLATE, \
+ TTI_DETAIL_TRAIT_ASSERT_NOT_NIL \
+ ) \
+ (trait,name,params) \
+/**/
+
+#define TTI_DETAIL_TRAIT_HAS_TEMPLATE(trait,name,params) \
+ BOOST_MPL_HAS_XXX_TEMPLATE_NAMED_DEF(BOOST_PP_CAT(trait,_detail_mpl), name, false) \
+ template<class TTI_T> \
+ struct trait : \
+ BOOST_PP_CAT(trait,_detail_mpl)<TTI_T> \
+ { \
+ }; \
+/**/
+
+#endif // BOOST_TTI_VERSION_1_6
+#endif // !TTI_DETAIL_TEMPLATE_HPP

Modified: trunk/boost/tti/detail/dtemplate_params.hpp
==============================================================================
--- trunk/boost/tti/detail/dtemplate_params.hpp (original)
+++ trunk/boost/tti/detail/dtemplate_params.hpp 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -13,13 +13,23 @@
 #include <boost/preprocessor/arithmetic/add.hpp>
 #include <boost/preprocessor/arithmetic/sub.hpp>
 #include <boost/preprocessor/array/elem.hpp>
-#include <boost/preprocessor/array/size.hpp>
+#include <boost/preprocessor/cat.hpp>
 #include <boost/preprocessor/punctuation/comma_if.hpp>
 #include <boost/preprocessor/repetition/repeat.hpp>
 #include <boost/preprocessor/repetition/enum.hpp>
+
+#if defined(BOOST_TTI_VERSION_1_6)
+
+#include <boost/preprocessor/array/enum.hpp>
+#include <boost/preprocessor/array/size.hpp>
+
+#else
+
 #include <boost/preprocessor/seq/enum.hpp>
 #include <boost/preprocessor/seq/size.hpp>
 
+#endif
+
 #if !defined(BOOST_MPL_CFG_NO_HAS_XXX_TEMPLATE)
 
 #define TTI_DETAIL_TEMPLATE_PARAMETERS(z,n,args) \
@@ -168,7 +178,8 @@
 /**/
 
 #endif // !BOOST_WORKAROUND(BOOST_MSVC, <= 1400)
-#else // !!defined(BOOST_MPL_CFG_NO_HAS_XXX_TEMPLATE)
+
+#else // defined(BOOST_MPL_CFG_NO_HAS_XXX_TEMPLATE)
 
 #define TTI_DETAIL_SAME(trait,name) \
   BOOST_MPL_HAS_XXX_TEMPLATE_NAMED_DEF \
@@ -179,8 +190,47 @@
     ) \
 /**/
 
+#define TTI_DETAIL_TRAIT_HAS_TEMPLATE_CHECK_PARAMS(trait,name,tp) \
+ TTI_DETAIL_SAME(trait,name) \
+/**/
+
+#endif // !BOOST_MPL_CFG_NO_HAS_XXX_TEMPLATE
+
+#if defined(BOOST_TTI_VERSION_1_6)
+
+#define TTI_TRAIT_HAS_TEMPLATE_CHECK_PARAMS(trait,name,tpArray) \
+ TTI_DETAIL_TRAIT_HAS_TEMPLATE_CHECK_PARAMS(BOOST_PP_CAT(trait,_detail),name,tpArray) \
+ template<class TTI_T> \
+ struct trait : \
+ BOOST_PP_CAT(trait,_detail)<TTI_T> \
+ { \
+ }; \
+/**/
+
+#if !defined(BOOST_MPL_CFG_NO_HAS_XXX_TEMPLATE)
+#if !BOOST_WORKAROUND(BOOST_MSVC, <= 1400)
+
+#define TTI_DETAIL_TRAIT_HAS_TEMPLATE_CHECK_PARAMS(trait,name,tpArray) \
+ TTI_DETAIL_HAS_MEMBER_WITH_FUNCTION_SFINAE \
+ ( \
+ ( BOOST_PP_ADD(BOOST_PP_ARRAY_SIZE(tpArray),4), ( trait, name, 1, false, BOOST_PP_ARRAY_ENUM(tpArray) ) ) \
+ ) \
+/**/
+
+#else // BOOST_WORKAROUND(BOOST_MSVC, <= 1400)
+
+#define TTI_DETAIL_TRAIT_HAS_TEMPLATE_CHECK_PARAMS(trait,name,tpArray) \
+ TTI_DETAIL_HAS_MEMBER_WITH_TEMPLATE_SFINAE \
+ ( \
+ ( BOOST_PP_ADD(BOOST_PP_ARRAY_SIZE(tpArray),4), ( trait, name, 1, false, BOOST_PP_ARRAY_ENUM(tpArray) ) ) \
+ ) \
+/**/
+
+#endif // !BOOST_WORKAROUND(BOOST_MSVC, <= 1400)
 #endif // !defined(BOOST_MPL_CFG_NO_HAS_XXX_TEMPLATE)
 
+#else // !BOOST_TTI_VERSION_1_6
+
 #if !defined(BOOST_MPL_CFG_NO_HAS_XXX_TEMPLATE)
 #if !BOOST_WORKAROUND(BOOST_MSVC, <= 1400)
 
@@ -191,7 +241,7 @@
     ) \
 /**/
 
-#else // !!BOOST_WORKAROUND(BOOST_MSVC, <= 1400)
+#else // BOOST_WORKAROUND(BOOST_MSVC, <= 1400)
 
 #define TTI_DETAIL_TRAIT_HAS_TEMPLATE_CHECK_PARAMS(trait,name,tpSeq) \
   TTI_DETAIL_HAS_MEMBER_WITH_TEMPLATE_SFINAE \
@@ -201,12 +251,8 @@
 /**/
 
 #endif // !BOOST_WORKAROUND(BOOST_MSVC, <= 1400)
-#else // !!defined(BOOST_MPL_CFG_NO_HAS_XXX_TEMPLATE)
-
-#define TTI_DETAIL_TRAIT_HAS_TEMPLATE_CHECK_PARAMS(trait,name,tpSeq) \
- TTI_DETAIL_SAME(trait,name) \
-/**/
-
 #endif // !defined(BOOST_MPL_CFG_NO_HAS_XXX_TEMPLATE)
 
+#endif // BOOST_TTI_VERSION_1_6
+
 #endif // TTI_DETAIL_TEMPLATE_PARAMS_HPP

Modified: trunk/boost/tti/detail/dvm_template_params.hpp
==============================================================================
--- trunk/boost/tti/detail/dvm_template_params.hpp (original)
+++ trunk/boost/tti/detail/dvm_template_params.hpp 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -7,6 +7,7 @@
 #if !defined(TTI_VM_DETAIL_TEMPLATE_PARAMS_HPP)
 #define TTI_VM_DETAIL_TEMPLATE_PARAMS_HPP
 
+#include <boost/config.hpp>
 #include <boost/preprocessor/config/config.hpp>
 
 #if BOOST_PP_VARIADICS
@@ -17,6 +18,21 @@
 #include <boost/preprocessor/variadic/size.hpp>
 #include "dtemplate_params.hpp"
 
+#if defined(BOOST_TTI_VERSION_1_6)
+
+#include <boost/preprocessor/cat.hpp>
+#include <boost/preprocessor/comparison/equal.hpp>
+#include <boost/preprocessor/control/iif.hpp>
+#include <boost/preprocessor/detail/is_binary.hpp>
+#include <boost/preprocessor/facilities/is_empty.hpp>
+#include <boost/preprocessor/seq/enum.hpp>
+#include <boost/preprocessor/seq/seq.hpp>
+#include <boost/preprocessor/variadic/elem.hpp>
+#include <boost/preprocessor/variadic/to_seq.hpp>
+#include "dtemplate.hpp"
+
+#endif
+
 #if !defined(BOOST_MPL_CFG_NO_HAS_XXX_TEMPLATE)
 #if !BOOST_WORKAROUND(BOOST_MSVC, <= 1400)
 
@@ -37,12 +53,105 @@
 /**/
 
 #endif // !BOOST_WORKAROUND(BOOST_MSVC, <= 1400)
-#else // !!defined(BOOST_MPL_CFG_NO_HAS_XXX_TEMPLATE)
+#else // defined(BOOST_MPL_CFG_NO_HAS_XXX_TEMPLATE)
 
 #define TTI_VM_DETAIL_TRAIT_HAS_TEMPLATE_CHECK_PARAMS(trait,name,...) \
   TTI_DETAIL_SAME(trait,name) \
 /**/
 
 #endif // !defined(BOOST_MPL_CFG_NO_HAS_XXX_TEMPLATE)
+
+#if defined(BOOST_TTI_VERSION_1_6)
+
+#define TTI_VM_DETAIL_CHECK_MORE_THAN_TWO(trait,...) \
+ BOOST_PP_IIF \
+ ( \
+ BOOST_PP_EQUAL \
+ ( \
+ BOOST_PP_VARIADIC_SIZE(__VA_ARGS__), \
+ 2 \
+ ), \
+ TTI_VM_DETAIL_TRAIT_CHOOSE_FROM_TWO, \
+ TTI_VM_DETAIL_TRAIT_EXPAND_ARGUMENTS \
+ ) \
+ (trait,__VA_ARGS__) \
+/**/
+
+#define TTI_VM_DETAIL_TRAIT_CHOOSE_FROM_TWO(trait,...) \
+ BOOST_PP_IIF \
+ ( \
+ BOOST_PP_IS_BINARY \
+ ( \
+ BOOST_PP_VARIADIC_ELEM(1,__VA_ARGS__) \
+ ), \
+ TTI_TRAIT_HAS_TEMPLATE_CHECK_PARAMS, \
+ TTI_VM_DETAIL_TRAIT_CHOOSE_IF_NIL \
+ ) \
+ ( \
+ trait, \
+ BOOST_PP_VARIADIC_ELEM(0,__VA_ARGS__), \
+ BOOST_PP_VARIADIC_ELEM(1,__VA_ARGS__) \
+ ) \
+/**/
+
+#define TTI_VM_DETAIL_IS_NIL(param) \
+ BOOST_PP_IS_EMPTY \
+ ( \
+ BOOST_PP_CAT(TTI_DETAIL_IS_HELPER_,param) \
+ ) \
+/**/
+
+#define TTI_VM_DETAIL_TRAIT_CHOOSE_IF_NIL(trait,name,param) \
+ BOOST_PP_IIF \
+ ( \
+ TTI_VM_DETAIL_IS_NIL(param), \
+ TTI_DETAIL_TRAIT_HAS_TEMPLATE, \
+ TTI_VM_DETAIL_CALL_TRAIT_HAS_TEMPLATE_CHECK_PARAMS \
+ ) \
+ (trait,name,param) \
+/**/
+
+#define TTI_VM_DETAIL_VARIADIC_TAIL(...) \
+ BOOST_PP_SEQ_ENUM \
+ ( \
+ BOOST_PP_SEQ_TAIL \
+ ( \
+ BOOST_PP_VARIADIC_TO_SEQ(__VA_ARGS__) \
+ ) \
+ ) \
+/**/
+
+#define TTI_VM_DETAIL_TRAIT_EXPAND_ARGUMENTS(trait,...) \
+ TTI_VM_DETAIL_CALL_TRAIT_HAS_TEMPLATE_CHECK_PARAMS \
+ ( \
+ trait, \
+ BOOST_PP_VARIADIC_ELEM(0,__VA_ARGS__), \
+ TTI_VM_DETAIL_VARIADIC_TAIL(__VA_ARGS__) \
+ ) \
+/**/
+
+#define TTI_VM_DETAIL_TRAIT_HAS_TEMPLATE(trait,...) \
+ TTI_DETAIL_TRAIT_HAS_TEMPLATE \
+ ( \
+ trait, \
+ BOOST_PP_VARIADIC_ELEM(0,__VA_ARGS__), \
+ BOOST_PP_NIL \
+ ) \
+/**/
+
+#define TTI_VM_DETAIL_CALL_TRAIT_HAS_TEMPLATE_CHECK_PARAMS(trait,name,...) \
+ TTI_VM_DETAIL_TRAIT_HAS_TEMPLATE_CHECK_PARAMS(BOOST_PP_CAT(trait,_detail),name,__VA_ARGS__) \
+ template<class TTI_T> \
+ struct trait \
+ { \
+ typedef typename BOOST_PP_CAT(trait,_detail)<TTI_T>::type type; \
+ \
+ BOOST_STATIC_CONSTANT(bool,value=type::value); \
+ }; \
+/**/
+
+#endif // BOOST_TTI_VERSION_1_6
+
 #endif // BOOST_PP_VARIADICS
+
 #endif // TTI_VM_DETAIL_TEMPLATE_PARAMS_HPP

Modified: trunk/boost/tti/gen/has_template_check_params_gen.hpp
==============================================================================
--- trunk/boost/tti/gen/has_template_check_params_gen.hpp (original)
+++ trunk/boost/tti/gen/has_template_check_params_gen.hpp 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -7,6 +7,8 @@
 #if !defined(TTI_TEMPLATE_PARAMS_GEN_HPP)
 #define TTI_TEMPLATE_PARAMS_GEN_HPP
 
+#if !defined(BOOST_TTI_VERSION_1_6)
+
 #include <boost/preprocessor/cat.hpp>
 
 /*
@@ -28,4 +30,6 @@
   BOOST_PP_CAT(has_template_check_params_,name) \
 /**/
 
+#endif
+
 #endif // TTI_TEMPLATE_PARAMS_GEN_HPP

Modified: trunk/boost/tti/gen/vm_has_template_check_params_gen.hpp
==============================================================================
--- trunk/boost/tti/gen/vm_has_template_check_params_gen.hpp (original)
+++ trunk/boost/tti/gen/vm_has_template_check_params_gen.hpp 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -7,6 +7,8 @@
 #if !defined(TTI_VM_TEMPLATE_PARAMS_GEN_HPP)
 #define TTI_VM_TEMPLATE_PARAMS_GEN_HPP
 
+#if !defined(BOOST_TTI_VERSION_1_6)
+
 #include <boost/preprocessor/config/config.hpp>
 
 #if BOOST_PP_VARIADICS
@@ -33,4 +35,5 @@
 /**/
 
 #endif // BOOST_PP_VARIADICS
+#endif
 #endif // TTI_VM_TEMPLATE_PARAMS_GEN_HPP

Modified: trunk/boost/tti/has_template.hpp
==============================================================================
--- trunk/boost/tti/has_template.hpp (original)
+++ trunk/boost/tti/has_template.hpp 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -4,22 +4,89 @@
 // Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
 // http://www.boost.org/LICENSE_1_0.txt).
 
+/*
+
+ The succeeding comments in this file are in doxygen format.
+
+*/
+
+/** \file
+*/
+
 #if !defined(TTI_HAS_TEMPLATE_HPP)
 #define TTI_HAS_TEMPLATE_HPP
 
 #include <boost/config.hpp>
-#include <boost/mpl/has_xxx.hpp>
-#include <boost/preprocessor/cat.hpp>
 #include <boost/tti/gen/has_template_gen.hpp>
 
-/*
+#if defined(BOOST_TTI_VERSION_1_6)
 
- The succeeding comments in this file are in doxygen format.
+#include <boost/preprocessor/config/config.hpp>
+#include <boost/preprocessor/control/iif.hpp>
 
-*/
+#if BOOST_PP_VARIADICS
 
-/** \file
-*/
+#include <boost/preprocessor/comparison/equal.hpp>
+#include <boost/preprocessor/variadic/elem.hpp>
+#include <boost/preprocessor/variadic/size.hpp>
+#include <boost/tti/detail/dvm_template_params.hpp>
+
+#define BOOST_TTI_TRAIT_HAS_TEMPLATE(trait,...) \
+ BOOST_PP_IIF \
+ ( \
+ BOOST_PP_EQUAL \
+ ( \
+ BOOST_PP_VARIADIC_SIZE(__VA_ARGS__), \
+ 1 \
+ ), \
+ TTI_VM_DETAIL_TRAIT_HAS_TEMPLATE, \
+ TTI_VM_DETAIL_CHECK_MORE_THAN_TWO \
+ ) \
+ (trait,__VA_ARGS__) \
+/**/
+
+#define BOOST_TTI_HAS_TEMPLATE(...) \
+ BOOST_TTI_TRAIT_HAS_TEMPLATE \
+ ( \
+ BOOST_TTI_HAS_TEMPLATE_GEN \
+ ( \
+ BOOST_PP_VARIADIC_ELEM(0,__VA_ARGS__) \
+ ), \
+ __VA_ARGS__ \
+ ) \
+/**/
+
+#else // !BOOST_PP_VARIADICS
+
+#include <boost/preprocessor/detail/is_binary.hpp>
+#include <boost/tti/detail/dtemplate.hpp>
+#include <boost/tti/detail/dtemplate_params.hpp>
+
+#define BOOST_TTI_TRAIT_HAS_TEMPLATE(trait,name,params) \
+ BOOST_PP_IIF \
+ ( \
+ BOOST_PP_IS_BINARY(params), \
+ TTI_TRAIT_HAS_TEMPLATE_CHECK_PARAMS, \
+ TTI_DETAIL_TRAIT_CHECK_IS_NIL \
+ ) \
+ (trait,name,params) \
+/**/
+
+#define BOOST_TTI_HAS_TEMPLATE(name,params) \
+ BOOST_TTI_TRAIT_HAS_TEMPLATE \
+ ( \
+ BOOST_TTI_HAS_TEMPLATE_GEN(name), \
+ name, \
+ params \
+ ) \
+/**/
+
+#endif // BOOST_PP_VARIADICS
+
+#else // !BOOST_TTI_VERSION_1_6
+
+#include <boost/mpl/has_xxx.hpp>
+#include <boost/preprocessor/cat.hpp>
 
 /// Expands to a metafunction which tests whether an inner class template with a particular name exists.
 /**
@@ -88,4 +155,5 @@
   ) \
 /**/
 
+#endif // BOOST_TTI_VERSION_1_6
 #endif // TTI_HAS_TEMPLATE_HPP

Modified: trunk/boost/tti/has_template_check_params.hpp
==============================================================================
--- trunk/boost/tti/has_template_check_params.hpp (original)
+++ trunk/boost/tti/has_template_check_params.hpp 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -7,6 +7,8 @@
 #if !defined(TTI_HAS_TEMPLATE_CHECK_PARAMS_HPP)
 #define TTI_HAS_TEMPLATE_CHECK_PARAMS_HPP
 
+#if !defined(BOOST_TTI_VERSION_1_6)
+
 #include <boost/config.hpp>
 #include <boost/preprocessor/cat.hpp>
 #include <boost/tti/gen/has_template_check_params_gen.hpp>
@@ -95,4 +97,5 @@
   ) \
 /**/
 
-#endif // TTI_HAS_TEMPLATE_CHECK_PARAMS_HPP
+#endif // !BOOST_TTI_VERSION_1_6
+#endif // !TTI_HAS_TEMPLATE_CHECK_PARAMS_HPP

Modified: trunk/boost/tti/vm_has_template_check_params.hpp
==============================================================================
--- trunk/boost/tti/vm_has_template_check_params.hpp (original)
+++ trunk/boost/tti/vm_has_template_check_params.hpp 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -7,6 +7,8 @@
 #if !defined(TTI_VM_HAS_TEMPLATE_CHECK_PARAMS_HPP)
 #define TTI_VM_HAS_TEMPLATE_CHECK_PARAMS_HPP
 
+#if !defined(BOOST_TTI_VERSION_1_6)
+
 #include <boost/preprocessor/config/config.hpp>
 
 #if BOOST_PP_VARIADICS
@@ -97,4 +99,5 @@
 /**/
 
 #endif // BOOST_PP_VARIADICS
+#endif // !BOOST_TTI_VERSION_1_6
 #endif // TTI_VM_HAS_TEMPLATE_CHECK_PARAMS_HPP

Deleted: trunk/libs/tti/doc/TypeTraitsIntrospection.pdf
==============================================================================
Binary file. No diff available.

Modified: trunk/libs/tti/doc/tti.qbk
==============================================================================
--- trunk/libs/tti/doc/tti.qbk (original)
+++ trunk/libs/tti/doc/tti.qbk 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -24,7 +24,6 @@
 [include tti_detail.qbk]
 [include tti_detail_has_type.qbk]
 [include tti_detail_has_template.qbk]
-[include tti_detail_has_template_check_params.qbk]
 [include tti_detail_has_member_data.qbk]
 [include tti_detail_has_member_function.qbk]
 [include tti_detail_has_member_function_with_sig.qbk]

Modified: trunk/libs/tti/doc/tti_detail.qbk
==============================================================================
--- trunk/libs/tti/doc/tti_detail.qbk (original)
+++ trunk/libs/tti/doc/tti_detail.qbk 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -68,7 +68,7 @@
     [[headerref boost/tti/has_type.hpp `has_type.hpp`]]
   ]
   [
- [Class Template]
+ [Class Template ( using variadic macros )]
     [
     [macroref BOOST_TTI_HAS_TEMPLATE](name)
     ]
@@ -82,28 +82,42 @@
     [[headerref boost/tti/has_template.hpp `has_template.hpp`]]
   ]
   [
- [Class Template with params]
+ [Class Template ( not using variadic macros )]
+ [
+ [macroref BOOST_TTI_HAS_TEMPLATE](name,BOOST_PP_NIL)
+ ]
+ [
+ `has_template_'name'`
+
+ class T = enclosing type
+
+ All of the template parameters must be 'class' ( or 'typename' ) parameters
+ ]
+ [[headerref boost/tti/has_template.hpp `has_template.hpp`]]
+ ]
+ [
+ [Class Template with params ( using variadic macros )]
     [
- [macroref BOOST_TTI_HAS_TEMPLATE_CHECK_PARAMS](name,ppSeq[footnote A Boost PP data sequence with each comma separated portion of the template parameters as its own sequence element.])
+ [macroref BOOST_TTI_HAS_TEMPLATE](name,...[footnote The template parameters as variadic data.])
     ]
     [
- `has_template_check_params_'name'`
+ `has_template_'name'`
     
     class T = enclosing type
     ]
- [[headerref boost/tti/has_template_check_params.hpp `has_template_check_params.hpp`]]
+ [[headerref boost/tti/has_template.hpp `has_template.hpp`]]
   ]
   [
- [Class Template with params using variadic macros[footnote General header file is `boost/tti/tti_vm.hpp`.]]
+ [Class Template with params]
     [
- [macroref BOOST_TTI_VM_HAS_TEMPLATE_CHECK_PARAMS](name,...[footnote The template parameters as variadic data.])
+ [macroref BOOST_TTI_HAS_TEMPLATE](name,ppArray[footnote The template parameters as the tuple part of the PP array.])
     ]
     [
- `has_template_check_params_'name'`
+ `has_template_'name'`
     
     class T = enclosing type
     ]
- [[headerref boost/tti/vm_has_template_check_params.hpp `vm_has_template_check_params.hpp`]]
+ [[headerref boost/tti/has_template.hpp `has_template.hpp`]]
   ]
   [
     [Member data]

Modified: trunk/libs/tti/doc/tti_detail_has_template.qbk
==============================================================================
--- trunk/libs/tti/doc/tti_detail_has_template.qbk (original)
+++ trunk/libs/tti/doc/tti_detail_has_template.qbk 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -7,14 +7,139 @@
 
 [section:tti_detail_has_template Introspecting an inner class template]
 
+[section:tti_detail_has_template_macro Using the BOOST_TTI_HAS_TEMPLATE macro]
+
 The TTI macro [macroref BOOST_TTI_HAS_TEMPLATE] introspects
-an inner class template of a class.
+an inner class template of a class. The macro must specify
+the name of the class template to introspect.
+
+[heading Two forms of introspection]
+
+There are two general forms of introspection which can be used.
+The first is to find a class template with any number of only
+template type parameters ( template parameters starting with `class`
+or `typename` ). In this form only the name of the class template
+needs to be specified when invoking the macro. We will call this form
+of the macro the `template type parameters` form. An example of a class
+template of this form which could be successfully introspected would be:
+
+ template<class X,typename Y,class Z,typename T> class AClassTemplate { /* etc. */ };
+
+The second is to find a class template with specific template parameters.
+In this form both the name of the class template and the template parameters
+are passed to the macro. We will call this form of the macro the
+`specific parameters` form. An example of a class template of this form which
+could be successfully introspected would be:
+
+ template<class X, template<class> class Y, int Z> BClassTemplate { /* etc. */ };
+
+[heading Variadic and non-variadic macro usage]
+
+When using the BOOST_TTI_HAS_TEMPLATE macro we distinguish between compilers
+supporting variadic macros or not supporting variadic macros.
+
+The programmer can always tell whether or not the compiler
+supports variadic macros by checking the value of the macro
+BOOST_PP_VARIADIC after including the necessary header file
+`boost/tti/has_template.hpp` in order to use the BOOST_TTI_TEMPLATE
+macro. A value of 1 indicates the compiler supports variadic macros
+while a value of 0 indicates the compiler does not support variadic
+macros.
+
+Modern C++ compilers, in supporting the latest C++11 standard,
+normally support variadic macros. Even before the latest C++11 standard
+a number of C++ compilers already supported variadic macros. If you feel
+your compiler supports variadic macros and BOOST_PP_VARIADIC is 0 even
+after including `boost/tti/has_template.hpp`, you can predefine BOOST_PP_VARIADIC
+to 1 before including `boost/tti/has_template.hpp`.
+
+[heading Non-variadic macro usage]
+
+We start with syntax for compilers not supporting variadic macros since this
+syntax can also be used by compilers which do support variadic macros. The
+form for non-variadic macros always takes two macro parameters. The first
+macro parameter is always the name of the class template you are trying to
+introspect.
+
+The second macro parameter, when using the `specific parameters` form of the
+macro, is the template parameters in the form of a Boost preprocessor library
+array data type. When using the `template type parameters` form of the macro
+the second macro parameter is BOOST_PP_NIL. If the second parameter is neither
+a Boost preprocessor library array data type or BOOS_PP_NIL you will get a
+compiler error if your compiler only supports non-variadic macros.
+
+The non-variadic macro form for introspecting the class templates above
+using the `template type parameters` form would be:
+
+ BOOST_TTI_TEMPLATE(AClassTemplate,BOOST_PP_NIL)
+ BOOST_TTI_TEMPLATE(BClassTemplate,BOOST_PP_NIL)
+
+Invoking the metafunction in the second case would always fail since the
+BClassTemplate does not have all template type parameters.
+
+The non-variadic macro form for introspecting the class templates above
+using the `specific parameters` form would be:
+
+ BOOST_TTI_TEMPLATE(AClassTemplate,(4,(class X,typename Y,class Z,typename T)))
+ BOOST_TTI_TEMPLATE(BClassTemplate,(3,(class X, template<class> class Y, int Z)))
+
+You need to be careful using the non-variadic `specific parameters` form
+to specify the correct number of array parameters. This can sometimes be
+tricky if you have a template template parameter, or a
+non-type template parameter which has parentheses
+surrounding part of the type specification. In the latter case,
+when parentheses surround a comma ( ',' ), do not count that as
+creating another Boost PP array token. Two examples:
+
+ template<void (*FunctionPointer)(int,long)> class CClassTemplate { /* etc. */ };
+ template<template<class,class> class T> class DClassTemplate { /* etc. */ };
+
+ BOOST_TTI_TEMPLATE(CClassTemplate,(1,(void (*FunctionPointer)(int,long))))
+ BOOST_TTI_TEMPLATE(DClassTemplate,(2,(template<class,class> class T)))
+
+In the case of using the macro to introspect CClassTemplate the number of
+Boost PP array parameters is 1, even though there is a comma separating
+the tokens in `void (*FunctionPointer)(int,long)`. This is because the
+comma is within parentheses.
+
+In the case of using the macro to introspect DClassTemplate the number of
+Boost PP array parameters is 2, because there is a comma separating the
+tokens in `template<class,class> class T`.
+
+[heading Variadic macro usage]
+
+Having the ability to use variadic macros makes the syntax for using
+BOOST_TTI_TEMPLATE easier to specify in both the `template type parameters`
+form and the `specific parameters` form of using the macro.
+This is because variadic macros can take a variable number of parameters.
+When using the variadic macro form the first macro parameter is always the name
+of the class template you are trying to introspect. You only specify
+further parameters when using the `specific parameters` form of the macro,
+in which case the further parameters to the macro are the specific template
+parameters.
+
+Introspecting the first class template above using the
+`template type parameters` form the variadic macro would be:
+
+ BOOST_TTI_TEMPLATE(AClassTemplate)
+
+Introspecting the other class templates above using the
+`specific parameters` form the variadic macros would be:
+
+ BOOST_TTI_TEMPLATE(BClassTemplate,class X,template<class> class Y, int Z)
+ BOOST_TTI_TEMPLATE(CClassTemplate,void (*FunctionPointer)(int,long))
+ BOOST_TTI_TEMPLATE(DClassTemplate,template<class,class> class T)
+
+Here we have no problem with counting the number of tuple tokens
+for the Boost PP array, nor do we have to specify BOOST_PP_NIL if
+we are using the `template type parameters` form. We simply type
+the template parameters as the remaining tokens of the variadic macro.
+
+[heading The resulting metafunction]
 
-BOOST_TTI_HAS_TEMPLATE takes a single
-parameter which is the name of an inner class template whose
-existence the programmer wants to check. The inner class template
-must have all class ( or typename ) template parameters. The macro
-generates a metafunction called 'has_template_'name_of_inner_class_template'.
+Using either form of the macro, whether using variadic or non-variadic
+syntax, the macro generates a metafunction called
+'has_template_'name_of_inner_class_template'.
 
 The metafunction can be invoked by passing it the enclosing type
 to introspect.
@@ -25,14 +150,33 @@
 called 'value'. This is true or false depending on whether the inner
 class template exists or not.
 
+[endsect]
+
+[section:tti_detail_has_template_metafunction Using the has_template_(xxx) metafunction]
+
 [heading Generating the metafunction]
 
 You generate the metafunction by invoking the macro with the name
 of an inner class template:
 
- BOOST_TTI_HAS_TEMPLATE(AType)
+ // `template type parameters` form
+
+ BOOST_TTI_HAS_TEMPLATE(AClassTemplate,BOOST_PP_NIL) // non-variadic macro
+ BOOST_TTI_HAS_TEMPLATE(AClassTemplate) // variadic macro
+
+ // `specific parameters` form
+
+ BOOST_TTI_HAS_TEMPLATE(AClassTemplate,(2,(class X,int Y))) // non-variadic macro
+ BOOST_TTI_HAS_TEMPLATE(AClassTemplate,class X,int Y) // variadic macro
   
-generates a metafunction called 'has_template_AType' in the current scope.
+generates a metafunction called 'has_template_AClassTemplate' in the current scope.
+
+If you want to introspect the same class template name using both the
+`template type parameters` form and the `specific parameters` form
+you will have the problem that you will be generating a metafunction
+of the same name and violating the C++ ODR rule. In this particular
+case you can use the alternate BOOST_TTI_TRAIT_HAS_TEMPLATE macro
+to name the particular metafunction which will be generated.
 
 [heading Invoking the metafunction]
 
@@ -47,12 +191,36 @@
 
  #include <boost/tti/has_template.hpp>
  
+ // Using variadic macro, `template type parameters`
+
  BOOST_TTI_HAS_TEMPLATE(Template1)
  BOOST_TTI_HAS_TEMPLATE(Template2)
  BOOST_TTI_HAS_TEMPLATE(Template3)
  BOOST_TTI_HAS_TEMPLATE(Template4)
  BOOST_TTI_HAS_TEMPLATE(Template5)
  
+ // or using non-variadic macro, `template type parameters`
+
+ BOOST_TTI_HAS_TEMPLATE(Template1,BOOST_PP_NIL)
+ BOOST_TTI_HAS_TEMPLATE(Template2,BOOST_PP_NIL)
+ BOOST_TTI_HAS_TEMPLATE(Template3,BOOST_PP_NIL)
+ BOOST_TTI_HAS_TEMPLATE(Template4,BOOST_PP_NIL)
+ BOOST_TTI_HAS_TEMPLATE(Template5,BOOST_PP_NIL)
+
+ // Using variadic macro, `specific parameters`
+
+ BOOST_TTI_HAS_TEMPLATE_CHECK_PARAMS(Template6,class X,int Y)
+ BOOST_TTI_HAS_TEMPLATE_CHECK_PARAMS(Template7,typename A,template<class,class> struct B,long C)
+ BOOST_TTI_HAS_TEMPLATE_CHECK_PARAMS(Template8,double X,typename Y)
+ BOOST_TTI_HAS_TEMPLATE_CHECK_PARAMS(Template9,typename A,class B,typename C,class D,typename E,short F)
+
+ // or using non-variadic macro, `specific parameters`
+
+ BOOST_TTI_HAS_TEMPLATE_CHECK_PARAMS(Template6,(2,(class X,int Y)))
+ BOOST_TTI_HAS_TEMPLATE_CHECK_PARAMS(Template7,(4,(typename A,template<class,class> struct B,long C)))
+ BOOST_TTI_HAS_TEMPLATE_CHECK_PARAMS(Template8,(2,(double X,typename Y)))
+ BOOST_TTI_HAS_TEMPLATE_CHECK_PARAMS(Template9,(6,(typename A,class B,typename C,class D,typename E,short F)))
+
 Next let us create some user-defined types we want to introspect.
 
  struct Top
@@ -67,6 +235,16 @@
    template <class X,typename Y> struct Template4 { };
    template <typename A,class B,typename C,class D,typename E> class Template5 { };
    };
+ struct Top3
+ {
+ template <class X,int Y> struct Template6 { };
+ template <typename A,template<class,class> struct B,long C> class Template7 { };
+ };
+ struct Top4
+ {
+ template <double X,typename Y> struct Template8 { };
+ template <typename A,class B,typename C,class D,typename E,short F> class Template9 { };
+ };
    
 Finally we invoke our metafunction and return our value.
 This all happens at compile time, and can be used by
@@ -78,7 +256,7 @@
  has_template_Template2<Top>::value; // true
  has_template_Template2<Top2>::value; // false
  
- has_template_Template3<Top>::value; // false, not all typename/class tempate parameters
+ has_template_Template3<Top>::value; // false, not all typename/class template parameters
  has_template_Template3<Top2>::value; // true
  
  has_template_Template4<Top>::value; // false
@@ -87,9 +265,23 @@
  has_template_Template5<Top>::value; // false
  has_template_Template5<Top2>::value; // true
   
+ has_template_Template6<Top3>::value; // true
+ has_template_Template6<Top4>::value; // false
+
+ has_template_Template7<Top3>::value; // true
+ has_template_Template7<Top4>::value; // false
+
+ has_template_Template8<Top3>::value; // false
+ has_template_Template8<Top4>::value; // true
+
+ has_template_Template9<Top3>::value; // false
+ has_template_Template9<Top4>::value; // true
+
 It should be noticed that once we create our metafunction for
 introspecting an inner class template by name, we can reuse the
 metafunction for introspecting any enclosing user-defined type
 for that name.
 
 [endsect]
+
+[endsect]

Modified: trunk/libs/tti/doc/tti_detail_has_template_check_params.qbk
==============================================================================
--- trunk/libs/tti/doc/tti_detail_has_template_check_params.qbk (original)
+++ trunk/libs/tti/doc/tti_detail_has_template_check_params.qbk 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -7,9 +7,11 @@
 
 [section:tti_detail_has_template_check_params Introspecting an inner class template with specific parameters]
 
-The TTI macro [macroref BOOST_TTI_HAS_TEMPLATE_CHECK_PARAMS]
-introspects an inner class template, with specific template
-parameters, of a class.
+The TTI macro [macroref BOOST_TTI_HAS_TEMPLATE],
+besides being used to introspect an inner class template
+with all class ( or typename ) template parameters,
+can also be used to introspect an inner class template
+with specific template parameters.
 
 BOOST_TTI_HAS_TEMPLATE_CHECK_PARAMS takes
 two macro parameters. The first is the name of an inner class template

Modified: trunk/libs/tti/doc/tti_functionality.qbk
==============================================================================
--- trunk/libs/tti/doc/tti_functionality.qbk (original)
+++ trunk/libs/tti/doc/tti_functionality.qbk 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -20,7 +20,7 @@
 * Does it have a static member data with a particular name and of a particular type ?
 
 These are the compile-time questions which the TTI library answers. It does this
-by creating metafunctions which can be used at compile-time using C++ macros.
+by creating metafunctions, which can be used at compile-time, using C++ macros.
 Each of the metafunctions created returns a compile time constant bool value
 which answers one of the above questions at compile time. When the particular
 element above exists the value is 'true', or more precisely boost::mpl::true_,
@@ -45,11 +45,11 @@
 # In the simplest macro form, which I call the simple form, the 'name' of the inner element
   is used directly to generate the name
   of the metafunction as well as serving as the 'name' to introspect. In generating the name of
- the metafunction from the macro name, the `BOOST_TTI_` ( or `BOOST_TTI_VM_` ) prefix is removed,
+ the metafunction from the macro name, the `BOOST_TTI_` prefix is removed,
   the rest of the macro name is changed to lower case, and an underscore ( '_' ) followed
   by the 'name' is appended. As an example, for the macro `BOOST_TTI_HAS_TYPE(MyType)` the
   name of the metafunction is `has_type_MyType` and it will look for an inner type called 'MyType'.
-# In the more complicated macro form, which I call the complex form, the macro starts with
+# In a more complicated macro form, which I call the complex form, the macro starts with
   `BOOST_TTI_TRAIT_` and a 'trait' name is passed as the first parameter, with the 'name' of the inner
   element as the second parameter. The 'trait' name serves solely to completely name the metafunction in
   whatever scope the macro is invoked. As an example, for the macro
@@ -61,7 +61,9 @@
 corresponding macro metafunction works exactly the same way and has the exact same functionality.
 
 In the succeeding documentation all macro metafunctions will be referred by their simple form
-name, but remember that the complex form can always be used instead.
+name, but remember that the complex form can always be used instead. The complex form is useful
+whenever using the simple form could create a duplicate name in the same name space, thereby
+violating the C++ one definition rule.
 
 [heading Macro Metafunction Name Generation]
 

Modified: trunk/libs/tti/doc/tti_introduction.qbk
==============================================================================
--- trunk/libs/tti/doc/tti_introduction.qbk (original)
+++ trunk/libs/tti/doc/tti_introduction.qbk 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -9,10 +9,14 @@
 
 Welcome to the Boost Type Traits Introspection library, abbreviated TTI.
 
-TTI is a library of macros generating metafunctions which provide the
-ability to introspect by name the elements of a type at compile time.
+TTI is a library which provides the ability to introspect by name the elements
+of a type at compile time.
 
-The name of the library is chosen because the library offers
+TTI works through macros generating metafunctions. The metafunctions are
+then used to introspect elements of a type at compile time, always passing
+at minimum to each metafunction the type being introspected.
+
+The name of the library has been chosen because the library offers
 compile time functionality on a type, similar to the Boost Type Traits library,
 and because the functionality the library offers is the ability to introspect
 a type about the existence of a specific element within that type.
@@ -20,9 +24,9 @@
 I use the word "introspect" in a very broad sense here. Normally language
 introspection means initially asking for information to be returned by name,
 which can then further be used to introspect for more specific information.
-In the TTI library one must always supply the name, and use the functionality
-provided for the correct type of inner element to find out if that particular
-named entity exists.
+In the TTI library one must always know and supply the name, and use the
+functionality provided for the correct type of inner element to find out
+if that particular named entity exists.
 
 You may prefer the term "query" instead of "introspection" to denote what this
 library does, but I use terminology based on the word "introspect" throughout
@@ -37,6 +41,11 @@
   element exists within the type. These generated metafunctions
   will be called "macro metafunctions" in the documentation.
    
+* Provide the means to create a typedef for a type which may
+ not exist. This typedef type can be used as a type in the
+ metafunctions of the library without producing compile-time
+ errors.
+
 The library is dependent on Boost PP, Boost MPL,
 Boost Type Traits, and Boost Function Types.
 
@@ -52,28 +61,55 @@
 
 [section:tti_headers Header Files]
 
-There are two separate general header files in the library,
-divided depending on whether or not the library
-functionality supporting variadic macros is to be used,
-which bring in all the rest of the specific header files.
-
-# The main header, which does not require using the library
-support for variadic macros, is `boost/tti/tti.hpp`.
-This can be used for the vast majority of functionality in the library.
-# The secondary header, which uses a small subset of the
-library functionality, providing an alternate use of particular
-macros with variadic macro support, is `boost/tti/tti_vm.hpp`.
-
-There are also separate specific header files for each of the elements to be
-introspected by the library. This allows for finer-grained inclusion
-of nested elements to be introspected. These individual header files
-will be given when discussing the individual elements.
-
-If the general header file `boost/tti/tti_vm.hpp`
-or the specific header file
-[headerref boost/tti/vm_has_template_check_params.hpp `vm_has_template_check_params.hpp`],
-are used, the library uses variadic macros and is also dependent
-on the variadic macro support of the Boost PP library.
+There are is a single header file, `boost/tti/tti.hpp`,
+which includes all the header files in the library.
+
+There are also separate specific header files for each of the elements
+to be introspected by the library. This allows for finer-grained inclusion
+of the nested elements to be introspected. These header files are:
+
+[table:tbhfiles TTI Header Files
+ [
+ [Introspected Element]
+ [Specific Header File]
+ ]
+ [
+ [Type]
+ [[headerref boost/tti/has_type.hpp `has_type.hpp`]]
+ ]
+ [
+ [Class Template]
+ [[headerref boost/tti/has_template.hpp `has_template.hpp`]]
+ ]
+ [
+ [Member data]
+ [[headerref boost/tti/has_member_data.hpp `has_member_data.hpp`]]
+ ]
+ [
+ [Member function as individual types]
+ [[headerref boost/tti/has_member_function.hpp `has_member_function.hpp`]]
+ ]
+ [
+ [Member function as a composite type]
+ [[headerref boost/tti/has_member_function_with_sig.hpp `has_member_function_with_sig.hpp`]]
+ ]
+ [
+ [Static member data]
+ [[headerref boost/tti/has_static_member_data.hpp `has_static_member_data.hpp`]]
+ ]
+ [
+ [Static member function as individual types]
+ [[headerref boost/tti/has_static_member_function.hpp `has_static_member_function.hpp`]]
+ ]
+ [
+ [Static member function as a composite type]
+ [[headerref boost/tti/has_static_member_function_with_sig.hpp `has_static_member_function_with_sig.hpp`]]
+ ]
+ [
+ [Member Type Creation]
+ [[headerref boost/tti/member_type.hpp `member_type.hpp`]]
+ ]
+]
 
 [endsect]
 

Modified: trunk/libs/tti/doc/tti_terminology.qbk
==============================================================================
--- trunk/libs/tti/doc/tti_terminology.qbk (original)
+++ trunk/libs/tti/doc/tti_terminology.qbk 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -28,7 +28,4 @@
 The term "generated metafunction(s)" refers to macro metafunctions
 which are generated by macros.
 
-The term "named metafunction(s)" refers to the specifically named
-nullary type metafunctions which are in the boost::tti namespace.
-
 [endsect]

Modified: trunk/libs/tti/test/Jamfile.v2
==============================================================================
--- trunk/libs/tti/test/Jamfile.v2 (original)
+++ trunk/libs/tti/test/Jamfile.v2 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -18,49 +18,239 @@
                                  <toolset>gcc-4.5.2:<cxxflags>-Wno-variadic-macros
                                  <toolset>gcc-4.6.0:<cxxflags>-Wno-variadic-macros
                                  ;
-
-alias tti
- :
- [ run test_has_member_const.cpp ]
+
+alias ttimfsig
+ :
         [ run test_has_member.cpp ]
         [ compile test_has_member_compile.cpp ]
         [ compile-fail test_has_member_fail.cpp ]
         [ compile-fail test_has_member_fail2.cpp ]
+ ;
+
+alias ttimd
+ :
         [ run test_has_mem_data.cpp ]
         [ compile test_has_mem_data_compile.cpp ]
         [ compile-fail test_has_mem_data_fail.cpp ]
         [ compile-fail test_has_mem_data_fail2.cpp ]
         [ compile-fail test_has_mem_data_fail3.cpp ]
+ ;
+
+alias ttimfn
+ :
         [ run test_has_mem_fun.cpp ]
- [ run test_has_mem_fun_const.cpp ]
         [ compile test_has_mem_fun_compile.cpp ]
         [ compile-fail test_has_mem_fun_fail.cpp ]
         [ compile-fail test_has_mem_fun_fail2.cpp ]
+ ;
+
+alias ttismfsig
+ :
         [ run test_has_static_member.cpp ]
         [ compile test_has_static_member_compile.cpp ]
         [ compile-fail test_has_static_member_fail.cpp ]
         [ compile-fail test_has_static_member_fail2.cpp ]
+ ;
+
+alias ttismd
+ :
         [ run test_has_static_mem_data.cpp ]
         [ compile test_has_static_mem_data_compile.cpp ]
         [ compile-fail test_has_static_mem_data_fail.cpp ]
         [ compile-fail test_has_static_mem_data_fail2.cpp ]
         [ compile-fail test_has_static_mem_data_fail3.cpp ]
+ ;
+
+alias ttismf
+ :
         [ run test_has_static_mem_fun.cpp ]
         [ compile test_has_static_mem_fun_compile.cpp ]
         [ compile-fail test_has_static_mem_fun_fail.cpp ]
         [ compile-fail test_has_static_mem_fun_fail2.cpp ]
- [ run test_has_template.cpp ]
- [ compile test_has_template_compile.cpp ]
- [ compile-fail test_has_template_fail.cpp ]
- [ compile-fail test_has_template_fail2.cpp ]
- [ compile-fail test_has_template_fail3.cpp ]
- [ compile-fail test_has_template_fail4.cpp ]
- [ run test_has_template_cp.cpp ]
- [ compile test_has_template_cp_compile.cpp ]
- [ compile-fail test_has_template_cp_fail.cpp ]
- [ compile-fail test_has_template_cp_fail2.cpp ]
- [ compile-fail test_has_template_cp_fail3.cpp ]
- [ compile-fail test_has_template_cp_fail4.cpp ]
+ ;
+
+alias ttitmp
+ :
+ [ run test_has_template.cpp : : : <define>BOOST_TTI_VERSION_1_6 <define>BOOST_PP_VARIADICS=0 ]
+ [ compile test_has_template_compile.cpp : <define>BOOST_TTI_VERSION_1_6 <define>BOOST_PP_VARIADICS=0 ]
+ [ compile-fail test_has_template_fail.cpp : <define>BOOST_TTI_VERSION_1_6 <define>BOOST_PP_VARIADICS=0 ]
+ [ compile-fail test_has_template_fail2.cpp : <define>BOOST_TTI_VERSION_1_6 <define>BOOST_PP_VARIADICS=0 ]
+ [ compile-fail test_has_template_fail3.cpp : <define>BOOST_TTI_VERSION_1_6 <define>BOOST_PP_VARIADICS=0 ]
+ [ compile-fail test_has_template_fail4.cpp : <define>BOOST_TTI_VERSION_1_6 <define>BOOST_PP_VARIADICS=0 ]
+ ;
+
+alias ttitmpv : :
+ <toolset>gcc
+ <toolset-gcc:version>3.4.2
+ ;
+
+alias ttitmpv : :
+ <toolset>gcc
+ <toolset-gcc:version>3.4.5
+ ;
+
+alias ttitmpv
+ :
+ [ run test_has_template.cpp : : :
+ <toolset>gcc-4.3.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.3.0:<cxxflags>-U__STRICT_ANSI__
+ <toolset>gcc-4.4.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.4.0:<cxxflags>-U__STRICT_ANSI__
+ <toolset>gcc-4.5.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.5.2:<cxxflags>-std=c++0x
+ <toolset>gcc-4.6.0:<cxxflags>-std=c++0x
+ <define>BOOST_TTI_VERSION_1_6
+ <define>BOOST_PP_VARIADICS=1 :
+ test_has_template_v ]
+ [ compile test_has_template_compile.cpp :
+ <toolset>gcc-4.3.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.3.0:<cxxflags>-U__STRICT_ANSI__
+ <toolset>gcc-4.4.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.4.0:<cxxflags>-U__STRICT_ANSI__
+ <toolset>gcc-4.5.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.5.2:<cxxflags>-std=c++0x
+ <toolset>gcc-4.6.0:<cxxflags>-std=c++0x
+ <define>BOOST_TTI_VERSION_1_6
+ <define>BOOST_PP_VARIADICS=1 :
+ test_has_template_compile_v ]
+ [ compile-fail test_has_template_fail.cpp :
+ <toolset>gcc-4.3.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.3.0:<cxxflags>-U__STRICT_ANSI__
+ <toolset>gcc-4.4.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.4.0:<cxxflags>-U__STRICT_ANSI__
+ <toolset>gcc-4.5.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.5.2:<cxxflags>-std=c++0x
+ <toolset>gcc-4.6.0:<cxxflags>-std=c++0x
+ <define>BOOST_TTI_VERSION_1_6
+ <define>BOOST_PP_VARIADICS=1 :
+ test_has_template_fail_v ]
+ [ compile-fail test_has_template_fail2.cpp :
+ <toolset>gcc-4.3.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.3.0:<cxxflags>-U__STRICT_ANSI__
+ <toolset>gcc-4.4.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.4.0:<cxxflags>-U__STRICT_ANSI__
+ <toolset>gcc-4.5.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.5.2:<cxxflags>-std=c++0x
+ <toolset>gcc-4.6.0:<cxxflags>-std=c++0x
+ <define>BOOST_TTI_VERSION_1_6
+ <define>BOOST_PP_VARIADICS=1 :
+ test_has_template_fail2_v ]
+ [ compile-fail test_has_template_fail3.cpp :
+ <toolset>gcc-4.3.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.3.0:<cxxflags>-U__STRICT_ANSI__
+ <toolset>gcc-4.4.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.4.0:<cxxflags>-U__STRICT_ANSI__
+ <toolset>gcc-4.5.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.5.2:<cxxflags>-std=c++0x
+ <toolset>gcc-4.6.0:<cxxflags>-std=c++0x
+ <define>BOOST_TTI_VERSION_1_6
+ <define>BOOST_PP_VARIADICS=1 :
+ test_has_template_fail3_v ]
+ [ compile-fail test_has_template_fail4.cpp :
+ <toolset>gcc-4.3.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.3.0:<cxxflags>-U__STRICT_ANSI__
+ <toolset>gcc-4.4.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.4.0:<cxxflags>-U__STRICT_ANSI__
+ <toolset>gcc-4.5.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.5.2:<cxxflags>-std=c++0x
+ <toolset>gcc-4.6.0:<cxxflags>-std=c++0x
+ <define>BOOST_TTI_VERSION_1_6
+ <define>BOOST_PP_VARIADICS=1 :
+ test_has_template_fail4_v ]
+ ;
+
+alias ttitmpcp
+ :
+ [ run test_has_template_cp.cpp : : : <define>BOOST_TTI_VERSION_1_6 <define>BOOST_PP_VARIADICS=0 ]
+ [ compile test_has_template_cp_compile.cpp : <define>BOOST_TTI_VERSION_1_6 <define>BOOST_PP_VARIADICS=0 ]
+ [ compile-fail test_has_template_cp_fail.cpp : <define>BOOST_TTI_VERSION_1_6 <define>BOOST_PP_VARIADICS=0 ]
+ [ compile-fail test_has_template_cp_fail2.cpp : <define>BOOST_TTI_VERSION_1_6 <define>BOOST_PP_VARIADICS=0 ]
+ [ compile-fail test_has_template_cp_fail3.cpp : <define>BOOST_TTI_VERSION_1_6 <define>BOOST_PP_VARIADICS=0 ]
+ [ compile-fail test_has_template_cp_fail4.cpp : <define>BOOST_TTI_VERSION_1_6 <define>BOOST_PP_VARIADICS=0 ]
+ ;
+
+alias ttitmpcpv : :
+ <toolset>gcc
+ <toolset-gcc:version>3.4.2
+ ;
+
+alias ttitmpcpv : :
+ <toolset>gcc
+ <toolset-gcc:version>3.4.5
+ ;
+
+alias ttitmpcpv
+ :
+ [ run test_has_template_cp.cpp : : :
+ <toolset>gcc-4.3.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.3.0:<cxxflags>-U__STRICT_ANSI__
+ <toolset>gcc-4.4.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.4.0:<cxxflags>-U__STRICT_ANSI__
+ <toolset>gcc-4.5.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.5.2:<cxxflags>-std=c++0x
+ <toolset>gcc-4.6.0:<cxxflags>-std=c++0x
+ <define>BOOST_TTI_VERSION_1_6
+ <define>BOOST_PP_VARIADICS=1 :
+ test_has_template_cp_v ]
+ [ compile test_has_template_cp_compile.cpp :
+ <toolset>gcc-4.3.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.3.0:<cxxflags>-U__STRICT_ANSI__
+ <toolset>gcc-4.4.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.4.0:<cxxflags>-U__STRICT_ANSI__
+ <toolset>gcc-4.5.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.5.2:<cxxflags>-std=c++0x
+ <toolset>gcc-4.6.0:<cxxflags>-std=c++0x
+ <define>BOOST_TTI_VERSION_1_6
+ <define>BOOST_PP_VARIADICS=1 :
+ test_has_template_cp_compile_v ]
+ [ compile-fail test_has_template_cp_fail.cpp :
+ <toolset>gcc-4.3.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.3.0:<cxxflags>-U__STRICT_ANSI__
+ <toolset>gcc-4.4.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.4.0:<cxxflags>-U__STRICT_ANSI__
+ <toolset>gcc-4.5.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.5.2:<cxxflags>-std=c++0x
+ <toolset>gcc-4.6.0:<cxxflags>-std=c++0x
+ <define>BOOST_TTI_VERSION_1_6
+ <define>BOOST_PP_VARIADICS=1 :
+ test_has_template_cp_fail_v ]
+ [ compile-fail test_has_template_cp_fail2.cpp :
+ <toolset>gcc-4.3.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.3.0:<cxxflags>-U__STRICT_ANSI__
+ <toolset>gcc-4.4.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.4.0:<cxxflags>-U__STRICT_ANSI__
+ <toolset>gcc-4.5.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.5.2:<cxxflags>-std=c++0x
+ <toolset>gcc-4.6.0:<cxxflags>-std=c++0x
+ <define>BOOST_TTI_VERSION_1_6
+ <define>BOOST_PP_VARIADICS=1 :
+ test_has_template_cp_fail2_v ]
+ [ compile-fail test_has_template_cp_fail3.cpp :
+ <toolset>gcc-4.3.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.3.0:<cxxflags>-U__STRICT_ANSI__
+ <toolset>gcc-4.4.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.4.0:<cxxflags>-U__STRICT_ANSI__
+ <toolset>gcc-4.5.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.5.2:<cxxflags>-std=c++0x
+ <toolset>gcc-4.6.0:<cxxflags>-std=c++0x
+ <define>BOOST_TTI_VERSION_1_6
+ <define>BOOST_PP_VARIADICS=1 :
+ test_has_template_cp_fail3_v ]
+ [ compile-fail test_has_template_cp_fail4.cpp :
+ <toolset>gcc-4.3.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.3.0:<cxxflags>-U__STRICT_ANSI__
+ <toolset>gcc-4.4.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.4.0:<cxxflags>-U__STRICT_ANSI__
+ <toolset>gcc-4.5.0:<cxxflags>-std=c++0x
+ <toolset>gcc-4.5.2:<cxxflags>-std=c++0x
+ <toolset>gcc-4.6.0:<cxxflags>-std=c++0x
+ <define>BOOST_TTI_VERSION_1_6
+ <define>BOOST_PP_VARIADICS=1 :
+ test_has_template_cp_fail4_v ]
+ ;
+
+alias ttity
+ :
         [ run test_has_type.cpp ]
         [ compile test_has_type_compile.cpp ]
         [ compile-fail test_has_type_fail.cpp ]
@@ -73,54 +263,29 @@
         [ compile-fail test_has_type_ct_fail3.cpp ]
         [ compile-fail test_has_type_ct_fail4.cpp ]
         [ compile-fail test_has_type_ct_fail5.cpp ]
+ ;
+
+alias ttimemty
+ :
         [ run test_mem_type.cpp ]
         [ compile test_mem_type_compile.cpp ]
- [ run test_mf_has_mem_data.cpp ]
- [ compile test_mf_has_mem_data_compile.cpp ]
- [ compile-fail test_mf_has_mem_data_fail.cpp ]
- [ compile-fail test_mf_has_mem_data_fail2.cpp ]
- [ compile-fail test_mf_has_mem_data_fail3.cpp ]
- [ run test_mf_has_mem_fun.cpp ]
- [ compile test_mf_has_mem_fun_compile.cpp ]
- [ compile-fail test_mf_has_mem_fun_fail.cpp ]
- [ compile-fail test_mf_has_mem_fun_fail2.cpp ]
- [ compile-fail test_mf_has_mem_fun_fail3.cpp ]
- [ run test_mf_has_static_data.cpp ]
- [ compile test_mf_has_static_data_compile.cpp ]
- [ compile-fail test_mf_has_static_data_fail.cpp ]
- [ compile-fail test_mf_has_static_data_fail2.cpp ]
- [ compile-fail test_mf_has_static_data_fail3.cpp ]
- [ run test_mf_has_static_fun.cpp ]
- [ compile test_mf_has_static_fun_compile.cpp ]
- [ compile-fail test_mf_has_static_fun_fail.cpp ]
- [ compile-fail test_mf_has_static_fun_fail2.cpp ]
- [ compile-fail test_mf_has_static_fun_fail3.cpp ]
- [ run test_mf_has_template.cpp ]
- [ compile test_mf_has_template_compile.cpp ]
- [ compile-fail test_mf_has_template_fail.cpp ]
- [ compile-fail test_mf_has_template_fail2.cpp ]
- [ compile-fail test_mf_has_template_fail3.cpp ]
- [ compile-fail test_mf_has_template_fail4.cpp ]
- [ run test_mf_has_template_cp.cpp ]
- [ compile test_mf_has_template_cp_compile.cpp ]
- [ compile-fail test_mf_has_template_cp_fail.cpp ]
- [ compile-fail test_mf_has_template_cp_fail2.cpp ]
- [ compile-fail test_mf_has_template_cp_fail3.cpp ]
- [ run test_mf_has_type.cpp ]
- [ compile test_mf_has_type_compile.cpp ]
- [ compile-fail test_mf_has_type_fail.cpp ]
- [ compile-fail test_mf_has_type_fail2.cpp ]
- [ run test_mf_has_type_ct.cpp ]
- [ compile test_mf_has_type_ct_compile.cpp ]
- [ compile-fail test_mf_has_type_ct_fail.cpp ]
- [ compile-fail test_mf_has_type_ct_fail2.cpp ]
- [ compile-fail test_mf_has_type_ct_fail3.cpp ]
- [ run test_mf_mem_type.cpp ]
- [ compile test_mf_mem_type_compile.cpp ]
     ;
 
+
+alias tti : ttimfsig ttimd ttimfn ttismfsig ttismd ttismf ttitmp ttitmpcp ttity ttimemty ;
+
+alias ttivm : :
+ <toolset>gcc
+ <toolset-gcc:version>3.4.2
+ ;
+
+alias ttivm : :
+ <toolset>gcc
+ <toolset-gcc:version>3.4.5
+ ;
+
 alias ttivm
- :
+ :
         [ run test_vm_has_template_cp.cpp : : :
           <toolset>gcc-4.3.0:<cxxflags>-std=c++0x
           <toolset>gcc-4.3.0:<cxxflags>-U__STRICT_ANSI__
@@ -129,6 +294,7 @@
           <toolset>gcc-4.5.0:<cxxflags>-std=c++0x
           <toolset>gcc-4.5.2:<cxxflags>-std=c++0x
           <toolset>gcc-4.6.0:<cxxflags>-std=c++0x
+ <define>BOOST_TTI_VERSION_1_6
           <define>BOOST_PP_VARIADICS=1 ]
         [ compile test_vm_has_template_cp_compile.cpp :
           <toolset>gcc-4.3.0:<cxxflags>-std=c++0x
@@ -138,6 +304,7 @@
           <toolset>gcc-4.5.0:<cxxflags>-std=c++0x
           <toolset>gcc-4.5.2:<cxxflags>-std=c++0x
           <toolset>gcc-4.6.0:<cxxflags>-std=c++0x
+ <define>BOOST_TTI_VERSION_1_6
           <define>BOOST_PP_VARIADICS=1 ]
         [ compile-fail test_vm_has_template_cp_fail.cpp :
           <toolset>gcc-4.3.0:<cxxflags>-std=c++0x
@@ -147,6 +314,7 @@
           <toolset>gcc-4.5.0:<cxxflags>-std=c++0x
           <toolset>gcc-4.5.2:<cxxflags>-std=c++0x
           <toolset>gcc-4.6.0:<cxxflags>-std=c++0x
+ <define>BOOST_TTI_VERSION_1_6
           <define>BOOST_PP_VARIADICS=1 ]
         [ compile-fail test_vm_has_template_cp_fail2.cpp :
           <toolset>gcc-4.3.0:<cxxflags>-std=c++0x
@@ -156,6 +324,7 @@
           <toolset>gcc-4.5.0:<cxxflags>-std=c++0x
           <toolset>gcc-4.5.2:<cxxflags>-std=c++0x
           <toolset>gcc-4.6.0:<cxxflags>-std=c++0x
+ <define>BOOST_TTI_VERSION_1_6
           <define>BOOST_PP_VARIADICS=1 ]
         [ compile-fail test_vm_has_template_cp_fail3.cpp :
           <toolset>gcc-4.3.0:<cxxflags>-std=c++0x
@@ -165,6 +334,7 @@
           <toolset>gcc-4.5.0:<cxxflags>-std=c++0x
           <toolset>gcc-4.5.2:<cxxflags>-std=c++0x
           <toolset>gcc-4.6.0:<cxxflags>-std=c++0x
+ <define>BOOST_TTI_VERSION_1_6
           <define>BOOST_PP_VARIADICS=1 ]
         [ compile-fail test_vm_has_template_cp_fail4.cpp :
           <toolset>gcc-4.3.0:<cxxflags>-std=c++0x
@@ -174,7 +344,64 @@
           <toolset>gcc-4.5.0:<cxxflags>-std=c++0x
           <toolset>gcc-4.5.2:<cxxflags>-std=c++0x
           <toolset>gcc-4.6.0:<cxxflags>-std=c++0x
+ <define>BOOST_TTI_VERSION_1_6
           <define>BOOST_PP_VARIADICS=1 ]
+ ;
+
+alias ttitemplate : ttitmp ttitmpcp ;
+
+alias ttitemplate_vm : ttitmpv ttitmpcpv ttivm ;
+
+alias ttitemplate_all : ttitemplate ttitemplate_vm ;
+
+alias ttimf
+ :
+ [ run test_mf_has_mem_data.cpp ]
+ [ compile test_mf_has_mem_data_compile.cpp ]
+ [ compile-fail test_mf_has_mem_data_fail.cpp ]
+ [ compile-fail test_mf_has_mem_data_fail2.cpp ]
+ [ compile-fail test_mf_has_mem_data_fail3.cpp ]
+ [ run test_mf_has_mem_fun.cpp ]
+ [ compile test_mf_has_mem_fun_compile.cpp ]
+ [ compile-fail test_mf_has_mem_fun_fail.cpp ]
+ [ compile-fail test_mf_has_mem_fun_fail2.cpp ]
+ [ compile-fail test_mf_has_mem_fun_fail3.cpp ]
+ [ run test_mf_has_static_data.cpp ]
+ [ compile test_mf_has_static_data_compile.cpp ]
+ [ compile-fail test_mf_has_static_data_fail.cpp ]
+ [ compile-fail test_mf_has_static_data_fail2.cpp ]
+ [ compile-fail test_mf_has_static_data_fail3.cpp ]
+ [ run test_mf_has_static_fun.cpp ]
+ [ compile test_mf_has_static_fun_compile.cpp ]
+ [ compile-fail test_mf_has_static_fun_fail.cpp ]
+ [ compile-fail test_mf_has_static_fun_fail2.cpp ]
+ [ compile-fail test_mf_has_static_fun_fail3.cpp ]
+ [ run test_mf_has_template.cpp ]
+ [ compile test_mf_has_template_compile.cpp ]
+ [ compile-fail test_mf_has_template_fail.cpp ]
+ [ compile-fail test_mf_has_template_fail2.cpp ]
+ [ compile-fail test_mf_has_template_fail3.cpp ]
+ [ compile-fail test_mf_has_template_fail4.cpp ]
+ [ run test_mf_has_template_cp.cpp ]
+ [ compile test_mf_has_template_cp_compile.cpp ]
+ [ compile-fail test_mf_has_template_cp_fail.cpp ]
+ [ compile-fail test_mf_has_template_cp_fail2.cpp ]
+ [ compile-fail test_mf_has_template_cp_fail3.cpp ]
+ [ run test_mf_has_type.cpp ]
+ [ compile test_mf_has_type_compile.cpp ]
+ [ compile-fail test_mf_has_type_fail.cpp ]
+ [ compile-fail test_mf_has_type_fail2.cpp ]
+ [ run test_mf_has_type_ct.cpp ]
+ [ compile test_mf_has_type_ct_compile.cpp ]
+ [ compile-fail test_mf_has_type_ct_fail.cpp ]
+ [ compile-fail test_mf_has_type_ct_fail2.cpp ]
+ [ compile-fail test_mf_has_type_ct_fail3.cpp ]
+ [ run test_mf_mem_type.cpp ]
+ [ compile test_mf_mem_type_compile.cpp ]
+ ;
+
+alias ttivmmf
+ :
         [ run test_vm_mf_has_template_cp.cpp : : :
           <toolset>gcc-4.3.0:<cxxflags>-std=c++0x
           <toolset>gcc-4.3.0:<cxxflags>-U__STRICT_ANSI__

Modified: trunk/libs/tti/test/test_has_template.hpp
==============================================================================
--- trunk/libs/tti/test/test_has_template.hpp (original)
+++ trunk/libs/tti/test/test_has_template.hpp 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -10,6 +10,34 @@
 #include "test_structs.hpp"
 #include <boost/tti/has_template.hpp>
 
+#if defined(BOOST_TTI_VERSION_1_6)
+
+#if BOOST_PP_VARIADICS
+
+BOOST_TTI_HAS_TEMPLATE(ATPMemberTemplate)
+BOOST_TTI_TRAIT_HAS_TEMPLATE(HaveCL,CLMemberTemplate,BOOST_PP_NIL)
+BOOST_TTI_HAS_TEMPLATE(AMemberTemplate)
+BOOST_TTI_TRAIT_HAS_TEMPLATE(HaveAnotherMT,AnotherMemberTemplate,BOOST_PP_NIL)
+BOOST_TTI_HAS_TEMPLATE(SomeMemberTemplate,BOOST_PP_NIL)
+BOOST_TTI_TRAIT_HAS_TEMPLATE(ATemplateWithParms,ManyParameters)
+BOOST_TTI_HAS_TEMPLATE(SimpleTMP,BOOST_PP_NIL)
+BOOST_TTI_HAS_TEMPLATE(TemplateNotExist)
+
+#else
+
+BOOST_TTI_HAS_TEMPLATE(ATPMemberTemplate,BOOST_PP_NIL)
+BOOST_TTI_TRAIT_HAS_TEMPLATE(HaveCL,CLMemberTemplate,BOOST_PP_NIL)
+BOOST_TTI_HAS_TEMPLATE(AMemberTemplate,BOOST_PP_NIL)
+BOOST_TTI_TRAIT_HAS_TEMPLATE(HaveAnotherMT,AnotherMemberTemplate,BOOST_PP_NIL)
+BOOST_TTI_HAS_TEMPLATE(SomeMemberTemplate,BOOST_PP_NIL)
+BOOST_TTI_TRAIT_HAS_TEMPLATE(ATemplateWithParms,ManyParameters,BOOST_PP_NIL)
+BOOST_TTI_HAS_TEMPLATE(SimpleTMP,BOOST_PP_NIL)
+BOOST_TTI_HAS_TEMPLATE(TemplateNotExist,BOOST_PP_NIL)
+
+#endif
+
+#else // !(BOOST_TTI_VERSION_1_6)
+
 BOOST_TTI_HAS_TEMPLATE(ATPMemberTemplate)
 BOOST_TTI_TRAIT_HAS_TEMPLATE(HaveCL,CLMemberTemplate)
 BOOST_TTI_HAS_TEMPLATE(AMemberTemplate)
@@ -19,4 +47,6 @@
 BOOST_TTI_HAS_TEMPLATE(SimpleTMP)
 BOOST_TTI_HAS_TEMPLATE(TemplateNotExist)
 
+#endif // BOOST_TTI_VERSION_1_6 && !BOOST_PP_VARIADICS
+
 #endif // TEST_HAS_TEMPLATE_HPP

Modified: trunk/libs/tti/test/test_has_template_cp.cpp
==============================================================================
--- trunk/libs/tti/test/test_has_template_cp.cpp (original)
+++ trunk/libs/tti/test/test_has_template_cp.cpp 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -10,15 +10,28 @@
 int main()
   {
   
+#if defined(BOOST_TTI_VERSION_1_6)
+
+ BOOST_TEST(BOOST_TTI_HAS_TEMPLATE_GEN(ATPMemberTemplate)<AType>::value);
+ BOOST_TEST(BOOST_TTI_HAS_TEMPLATE_GEN(AMemberTemplate)<AType>::value);
+ BOOST_TEST(BOOST_TTI_HAS_TEMPLATE_GEN(SomeMemberTemplate)<AnotherType>::value);
+ BOOST_TEST(BOOST_TTI_HAS_TEMPLATE_GEN(SimpleTMP)<AnotherType>::value);
+ BOOST_TEST(!BOOST_TTI_HAS_TEMPLATE_GEN(TemplateNotExist)<AnotherType>::value);
+
+#else // !BOOST_TTI_VERSION_1_6
+
   BOOST_TEST(BOOST_TTI_HAS_TEMPLATE_CHECK_PARAMS_GEN(ATPMemberTemplate)<AType>::value);
- BOOST_TEST(HaveCL<AType>::value);
   BOOST_TEST(BOOST_TTI_HAS_TEMPLATE_CHECK_PARAMS_GEN(AMemberTemplate)<AType>::value);
- BOOST_TEST(HaveAnotherMT<AType>::value);
   BOOST_TEST(BOOST_TTI_HAS_TEMPLATE_CHECK_PARAMS_GEN(SomeMemberTemplate)<AnotherType>::value);
- BOOST_TEST(ATemplateWithParms<AnotherType>::value);
   BOOST_TEST(BOOST_TTI_HAS_TEMPLATE_CHECK_PARAMS_GEN(SimpleTMP)<AnotherType>::value);
   BOOST_TEST(!BOOST_TTI_HAS_TEMPLATE_CHECK_PARAMS_GEN(TemplateNotExist)<AnotherType>::value);
 
+#endif // BOOST_TTI_VERSION_1_6
+
+ BOOST_TEST(HaveCL<AType>::value);
+ BOOST_TEST(HaveAnotherMT<AType>::value);
+ BOOST_TEST(ATemplateWithParms<AnotherType>::value);
+
   return boost::report_errors();
 
   }

Modified: trunk/libs/tti/test/test_has_template_cp.hpp
==============================================================================
--- trunk/libs/tti/test/test_has_template_cp.hpp (original)
+++ trunk/libs/tti/test/test_has_template_cp.hpp 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -8,6 +8,24 @@
 #define TEST_HAS_TEMPLATE_CHECK_PARAMS_HPP
 
 #include "test_structs.hpp"
+
+#if defined(BOOST_TTI_VERSION_1_6)
+
+#include <boost/tti/has_template.hpp>
+
+BOOST_TTI_HAS_TEMPLATE(ATPMemberTemplate,(1,(class)))
+BOOST_TTI_TRAIT_HAS_TEMPLATE(HaveCL,CLMemberTemplate,(2,(class,class)))
+BOOST_TTI_HAS_TEMPLATE(AMemberTemplate,(1,(int)))
+BOOST_TTI_TRAIT_HAS_TEMPLATE(HaveAnotherMT,AnotherMemberTemplate,(2,(int,int)))
+BOOST_TTI_HAS_TEMPLATE(SomeMemberTemplate,(6,(class,class,class,class,class,class)))
+BOOST_TTI_TRAIT_HAS_TEMPLATE(ATemplateWithParms,ManyParameters,(7,(class,class,int,class,template <class> class,class,long)))
+BOOST_TTI_HAS_TEMPLATE(SimpleTMP,(4,(class,class,class,class)))
+BOOST_TTI_HAS_TEMPLATE(TemplateNotExist,(3,(int,class,template <class> class ATemplate)))
+BOOST_TTI_TRAIT_HAS_TEMPLATE(WrongParametersForMP,ManyParameters,(8,(class,class,int,class,template <class,class> class InnerTemplate,class,long)))
+BOOST_TTI_TRAIT_HAS_TEMPLATE(WrongParameters2ForMP,ManyParameters,(7,(class,long,int,class,template <class> class InnerTemplate,class,long)))
+
+#else // !BOOST_TTI_VERSION_1_6
+
 #include <boost/tti/has_template_check_params.hpp>
 
 BOOST_TTI_HAS_TEMPLATE_CHECK_PARAMS(ATPMemberTemplate,(class))
@@ -21,4 +39,6 @@
 BOOST_TTI_TRAIT_HAS_TEMPLATE_CHECK_PARAMS(WrongParametersForMP,ManyParameters,(class)(class)(int)(class)(template <class)(class> class InnerTemplate)(class)(long))
 BOOST_TTI_TRAIT_HAS_TEMPLATE_CHECK_PARAMS(WrongParameters2ForMP,ManyParameters,(class)(long)(int)(class)(template <class> class InnerTemplate)(class)(long))
 
+#endif // BOOST_TTI_VERSION_1_6
+
 #endif // TEST_HAS_TEMPLATE_CHECK_PARAMS_HPP

Modified: trunk/libs/tti/test/test_has_template_cp_compile.cpp
==============================================================================
--- trunk/libs/tti/test/test_has_template_cp_compile.cpp (original)
+++ trunk/libs/tti/test/test_has_template_cp_compile.cpp 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -10,6 +10,21 @@
 int main()
   {
   
+#if defined(BOOST_TTI_VERSION_1_6)
+
+ // You can always instantiate without compiler errors
+
+ BOOST_TTI_HAS_TEMPLATE_GEN(TemplateNotExist)<AnotherType> aVar1;
+
+ // Compile time asserts
+
+ BOOST_MPL_ASSERT((BOOST_TTI_HAS_TEMPLATE_GEN(ATPMemberTemplate)<AType>));
+ BOOST_MPL_ASSERT((BOOST_TTI_HAS_TEMPLATE_GEN(AMemberTemplate)<AType>));
+ BOOST_MPL_ASSERT((BOOST_TTI_HAS_TEMPLATE_GEN(SomeMemberTemplate)<AnotherType>));
+ BOOST_MPL_ASSERT((BOOST_TTI_HAS_TEMPLATE_GEN(SimpleTMP)<AnotherType>));
+
+#else
+
   // You can always instantiate without compiler errors
   
   BOOST_TTI_HAS_TEMPLATE_CHECK_PARAMS_GEN(TemplateNotExist)<AnotherType> aVar1;
@@ -17,13 +32,16 @@
   // Compile time asserts
   
   BOOST_MPL_ASSERT((BOOST_TTI_HAS_TEMPLATE_CHECK_PARAMS_GEN(ATPMemberTemplate)<AType>));
- BOOST_MPL_ASSERT((HaveCL<AType>));
   BOOST_MPL_ASSERT((BOOST_TTI_HAS_TEMPLATE_CHECK_PARAMS_GEN(AMemberTemplate)<AType>));
- BOOST_MPL_ASSERT((HaveAnotherMT<AType>));
   BOOST_MPL_ASSERT((BOOST_TTI_HAS_TEMPLATE_CHECK_PARAMS_GEN(SomeMemberTemplate)<AnotherType>));
- BOOST_MPL_ASSERT((ATemplateWithParms<AnotherType>));
   BOOST_MPL_ASSERT((BOOST_TTI_HAS_TEMPLATE_CHECK_PARAMS_GEN(SimpleTMP)<AnotherType>));
   
+#endif
+
+ BOOST_MPL_ASSERT((HaveCL<AType>));
+ BOOST_MPL_ASSERT((HaveAnotherMT<AType>));
+ BOOST_MPL_ASSERT((ATemplateWithParms<AnotherType>));
+
   return 0;
 
   }

Modified: trunk/libs/tti/test/test_has_template_cp_fail.cpp
==============================================================================
--- trunk/libs/tti/test/test_has_template_cp_fail.cpp (original)
+++ trunk/libs/tti/test/test_has_template_cp_fail.cpp 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -10,10 +10,21 @@
 int main()
   {
   
+
+#if defined(BOOST_TTI_VERSION_1_6)
+
+ // TemplateNotExist does not exist at all
+
+ BOOST_MPL_ASSERT((BOOST_TTI_HAS_TEMPLATE_GEN(TemplateNotExist)<AType>));
+
+#else
+
   // TemplateNotExist does not exist at all
   
   BOOST_MPL_ASSERT((BOOST_TTI_HAS_TEMPLATE_CHECK_PARAMS_GEN(TemplateNotExist)<AType>));
   
+#endif
+
   return 0;
 
   }

Modified: trunk/libs/tti/test/test_vm_has_template_cp.cpp
==============================================================================
--- trunk/libs/tti/test/test_vm_has_template_cp.cpp (original)
+++ trunk/libs/tti/test/test_vm_has_template_cp.cpp 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -12,15 +12,28 @@
   
 #if BOOST_PP_VARIADICS
 
+#if defined(BOOST_TTI_VERSION_1_6)
+
+ BOOST_TEST(BOOST_TTI_HAS_TEMPLATE_GEN(ATPMemberTemplate)<AType>::value);
+ BOOST_TEST(BOOST_TTI_HAS_TEMPLATE_GEN(AMemberTemplate)<AType>::value);
+ BOOST_TEST(BOOST_TTI_HAS_TEMPLATE_GEN(SomeMemberTemplate)<AnotherType>::value);
+ BOOST_TEST(BOOST_TTI_HAS_TEMPLATE_GEN(SimpleTMP)<AnotherType>::value);
+ BOOST_TEST(!BOOST_TTI_HAS_TEMPLATE_GEN(TemplateNotExist)<AnotherType>::value);
+
+#else
+
   BOOST_TEST(BOOST_TTI_VM_HAS_TEMPLATE_CHECK_PARAMS_GEN(ATPMemberTemplate)<AType>::value);
- BOOST_TEST(HaveCL<AType>::value);
   BOOST_TEST(BOOST_TTI_VM_HAS_TEMPLATE_CHECK_PARAMS_GEN(AMemberTemplate)<AType>::value);
- BOOST_TEST(HaveAnotherMT<AType>::value);
   BOOST_TEST(BOOST_TTI_VM_HAS_TEMPLATE_CHECK_PARAMS_GEN(SomeMemberTemplate)<AnotherType>::value);
- BOOST_TEST(ATemplateWithParms<AnotherType>::value);
   BOOST_TEST(BOOST_TTI_VM_HAS_TEMPLATE_CHECK_PARAMS_GEN(SimpleTMP)<AnotherType>::value);
   BOOST_TEST(!BOOST_TTI_VM_HAS_TEMPLATE_CHECK_PARAMS_GEN(TemplateNotExist)<AnotherType>::value);
 
+#endif
+
+ BOOST_TEST(HaveCL<AType>::value);
+ BOOST_TEST(HaveAnotherMT<AType>::value);
+ BOOST_TEST(ATemplateWithParms<AnotherType>::value);
+
 #endif // BOOST_PP_VARIADICS
 
   return boost::report_errors();

Modified: trunk/libs/tti/test/test_vm_has_template_cp.hpp
==============================================================================
--- trunk/libs/tti/test/test_vm_has_template_cp.hpp (original)
+++ trunk/libs/tti/test/test_vm_has_template_cp.hpp 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -12,6 +12,24 @@
 #if BOOST_PP_VARIADICS
 
 #include "test_structs.hpp"
+
+#if defined(BOOST_TTI_VERSION_1_6)
+
+#include <boost/tti/has_template.hpp>
+
+BOOST_TTI_HAS_TEMPLATE(ATPMemberTemplate,class)
+BOOST_TTI_TRAIT_HAS_TEMPLATE(HaveCL,CLMemberTemplate,class,class)
+BOOST_TTI_HAS_TEMPLATE(AMemberTemplate,int)
+BOOST_TTI_TRAIT_HAS_TEMPLATE(HaveAnotherMT,AnotherMemberTemplate,int,int)
+BOOST_TTI_HAS_TEMPLATE(SomeMemberTemplate,class,class,class,class,class,class)
+BOOST_TTI_TRAIT_HAS_TEMPLATE(ATemplateWithParms,ManyParameters,class,class,int,class,template <class> class InnerTemplate,class,long)
+BOOST_TTI_HAS_TEMPLATE(SimpleTMP,class,class,class,class)
+BOOST_TTI_HAS_TEMPLATE(TemplateNotExist,int,class,template <class> class ATemplate)
+BOOST_TTI_TRAIT_HAS_TEMPLATE(WrongParametersForMP,ManyParameters,class,class,int,class,template <class,class> class InnerTemplate,class,long)
+BOOST_TTI_TRAIT_HAS_TEMPLATE(WrongParameters2ForMP,ManyParameters,class,long,int,class,template <class> class InnerTemplate,class,long)
+
+#else // !BOOST_TTI_VERSION_1_6
+
 #include <boost/tti/vm_has_template_check_params.hpp>
 
 BOOST_TTI_VM_HAS_TEMPLATE_CHECK_PARAMS(ATPMemberTemplate,class)
@@ -25,6 +43,8 @@
 BOOST_TTI_VM_TRAIT_HAS_TEMPLATE_CHECK_PARAMS(WrongParametersForMP,ManyParameters,class,class,int,class,template <class,class> class InnerTemplate,class,long)
 BOOST_TTI_VM_TRAIT_HAS_TEMPLATE_CHECK_PARAMS(WrongParameters2ForMP,ManyParameters,class,long,int,class,template <class> class InnerTemplate,class,long)
 
+#endif // BOOST_TTI_VERSION_1_6
+
 #endif // BOOST_PP_VARIADICS
 
 #endif // TEST_VM_HAS_TEMPLATE_CHECK_PARAMS_HPP

Modified: trunk/libs/tti/test/test_vm_has_template_cp_compile.cpp
==============================================================================
--- trunk/libs/tti/test/test_vm_has_template_cp_compile.cpp (original)
+++ trunk/libs/tti/test/test_vm_has_template_cp_compile.cpp 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -12,6 +12,21 @@
   
 #if BOOST_PP_VARIADICS
 
+#if defined(BOOST_TTI_VERSION_1_6)
+
+ // You can always instantiate without compiler errors
+
+ BOOST_TTI_HAS_TEMPLATE_GEN(TemplateNotExist)<AnotherType> aVar1;
+
+ // Compile time asserts
+
+ BOOST_MPL_ASSERT((BOOST_TTI_HAS_TEMPLATE_GEN(ATPMemberTemplate)<AType>));
+ BOOST_MPL_ASSERT((BOOST_TTI_HAS_TEMPLATE_GEN(AMemberTemplate)<AType>));
+ BOOST_MPL_ASSERT((BOOST_TTI_HAS_TEMPLATE_GEN(SomeMemberTemplate)<AnotherType>));
+ BOOST_MPL_ASSERT((BOOST_TTI_HAS_TEMPLATE_GEN(SimpleTMP)<AnotherType>));
+
+#else
+
   // You can always instantiate without compiler errors
   
   BOOST_TTI_VM_HAS_TEMPLATE_CHECK_PARAMS_GEN(TemplateNotExist)<AnotherType> aVar1;
@@ -19,13 +34,16 @@
   // Compile time asserts
   
   BOOST_MPL_ASSERT((BOOST_TTI_VM_HAS_TEMPLATE_CHECK_PARAMS_GEN(ATPMemberTemplate)<AType>));
- BOOST_MPL_ASSERT((HaveCL<AType>));
   BOOST_MPL_ASSERT((BOOST_TTI_VM_HAS_TEMPLATE_CHECK_PARAMS_GEN(AMemberTemplate)<AType>));
- BOOST_MPL_ASSERT((HaveAnotherMT<AType>));
   BOOST_MPL_ASSERT((BOOST_TTI_VM_HAS_TEMPLATE_CHECK_PARAMS_GEN(SomeMemberTemplate)<AnotherType>));
- BOOST_MPL_ASSERT((ATemplateWithParms<AnotherType>));
   BOOST_MPL_ASSERT((BOOST_TTI_VM_HAS_TEMPLATE_CHECK_PARAMS_GEN(SimpleTMP)<AnotherType>));
   
+#endif
+
+ BOOST_MPL_ASSERT((HaveCL<AType>));
+ BOOST_MPL_ASSERT((HaveAnotherMT<AType>));
+ BOOST_MPL_ASSERT((ATemplateWithParms<AnotherType>));
+
 #endif // BOOST_PP_VARIADICS
 
   return 0;

Modified: trunk/libs/tti/test/test_vm_has_template_cp_fail.cpp
==============================================================================
--- trunk/libs/tti/test/test_vm_has_template_cp_fail.cpp (original)
+++ trunk/libs/tti/test/test_vm_has_template_cp_fail.cpp 2012-11-04 19:18:16 EST (Sun, 04 Nov 2012)
@@ -12,10 +12,20 @@
   
 #if BOOST_PP_VARIADICS
 
+#if defined(BOOST_TTI_VERSION_1_6)
+
+ // TemplateNotExist does not exist at all
+
+ BOOST_MPL_ASSERT((BOOST_TTI_HAS_TEMPLATE_GEN(TemplateNotExist)<AType>));
+
+#else
+
   // TemplateNotExist does not exist at all
   
   BOOST_MPL_ASSERT((BOOST_TTI_VM_HAS_TEMPLATE_CHECK_PARAMS_GEN(TemplateNotExist)<AType>));
   
+#endif
+
 #else
   
   BOOST_MPL_ASSERT((boost::mpl::false_));


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk