1 | |
---|---|
2 | // (C) Copyright Edward Diener 2011 |
3 | // Use, modification and distribution are subject to the Boost Software License, |
4 | // Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at |
5 | // http://www.boost.org/LICENSE_1_0.txt). |
6 | |
7 | #include "test_vm_has_template_cp.hpp" |
8 | #include <boost/detail/lightweight_test.hpp> |
9 | |
10 | int main() |
11 | { |
12 | |
13 | #if BOOST_PP_VARIADICS |
14 | |
15 | BOOST_TEST(BOOST_TTI_HAS_TEMPLATE_GEN(ATPMemberTemplate)<AType>::value); |
16 | BOOST_TEST(BOOST_TTI_HAS_TEMPLATE_GEN(AMemberTemplate)<AType>::value); |
17 | BOOST_TEST(BOOST_TTI_HAS_TEMPLATE_GEN(SomeMemberTemplate)<AnotherType>::value); |
18 | BOOST_TEST(BOOST_TTI_HAS_TEMPLATE_GEN(SimpleTMP)<AnotherType>::value); |
19 | BOOST_TEST(!BOOST_TTI_HAS_TEMPLATE_GEN(TemplateNotExist)<AnotherType>::value); |
20 | |
21 | BOOST_TEST(HaveCL<AType>::value); |
22 | BOOST_TEST(HaveAnotherMT<AType>::value); |
23 | BOOST_TEST(ATemplateWithParms<AnotherType>::value); |
24 | |
25 | BOOST_TEST(BOOST_TTI_HAS_TEMPLATE_GEN(NestedMemberTemplate)<AType::AnUnion>::value); |
26 | |
27 | // Passing non-class enclosing type will return false |
28 | |
29 | BOOST_TEST(!BOOST_TTI_HAS_TEMPLATE_GEN(AMemberTemplate)<AType *>::value); |
30 | BOOST_TEST(!ATemplateWithParms<double>::value); |
31 | |
32 | #endif // BOOST_PP_VARIADICS |
33 | |
34 | return boost::report_errors(); |
35 | |
36 | } |
37 |