Add type_name<> tests for incomplete types. Refs #145.

This commit is contained in:
Peter Dimov 2023-05-21 05:40:24 +03:00
parent 5eb54d1d36
commit 97606908b7

View File

@ -47,10 +47,14 @@ class B
{
};
class C;
template<class T1, class T2> struct X
{
};
template<class T1, class T2> struct Y;
enum E1
{
e1
@ -63,6 +67,8 @@ enum class E2
e2
};
enum class E3;
#endif
struct Ch
@ -115,12 +121,14 @@ int main()
TEST(A);
TEST(B);
TEST(C);
TEST(E1);
#if !defined(BOOST_NO_CXX11_SCOPED_ENUMS)
TEST(E2);
TEST(E3);
#endif
@ -131,6 +139,10 @@ int main()
TEST(B&);
TEST(B const&);
TEST(C volatile);
TEST(C&);
TEST(C const&);
#if !defined(BOOST_NO_CXX11_RVALUE_REFERENCES)
TEST(B&&);
@ -141,6 +153,9 @@ int main()
TEST(A*);
TEST(B const* volatile*);
TEST(C*);
TEST(C const* volatile*);
TEST(void*);
TEST(void const* volatile*);
@ -290,6 +305,8 @@ int main()
TEST(std::pair<A, B>);
TEST(std::pair<A const*, B*> volatile&);
TEST(std::pair<C, C>);
TEST(std::pair<void, void>);
TEST(std::pair<std::pair<void, void>, void>);
@ -314,6 +331,11 @@ int main()
TEST(X<A, B>);
TEST(X<A const&, B&> volatile&);
TEST(X<C, C>);
TEST(Y<A, B>);
TEST(Y<C, C>);
TEST(X<std::pair<void, void>, void>);
TEST(std::vector<int>);