
Why do the macros add templates to the boost::tti namespace rather than the current one? One thing I get from the way MPL create the has_xxx metafunctions is that I can do this: template < typename T > struct obeys_xxx_concept { BOOST_MPL_HAS_XXX_TRAIT_DEF(some_trait) ... etc... enum { value = etc_checks<T>(0).... && has_some_trait<T>::value }; typedef boost::mpl::bool_<value> type; }; That wouldn't work with the TTI library it appears. What does putting the templates in the boost::tti namespace do for me to make up for this loss?

On 7/22/2011 7:46 PM, Noah Roberts wrote:
Why do the macros add templates to the boost::tti namespace rather than the current one?
One thing I get from the way MPL create the has_xxx metafunctions is that I can do this:
template < typename T > struct obeys_xxx_concept { BOOST_MPL_HAS_XXX_TRAIT_DEF(some_trait)
... etc...
enum { value = etc_checks<T>(0).... && has_some_trait<T>::value }; typedef boost::mpl::bool_<value> type; };
That wouldn't work with the TTI library it appears.
What does putting the templates in the boost::tti namespace do for me to make up for this loss?
I have already agreed that this is the wrong thing to do and I will not be putting the metafunctions created by the macros into any namespace. I am waiting until after the review results have been announced before I work on updating my library. Removing the metafunctions from the boost::tti namespace will be the first thing I do.
participants (3)
-
Edward Diener
-
Jeffrey Lee Hellrung, Jr.
-
Noah Roberts