Files
typeof/test/modifiers.cpp

17 lines
646 B
C++
Raw Normal View History

2006-09-09 17:25:09 +00:00
// Copyright (C) 2006 Arkadiy Vertleyb
// Use, modification and distribution is subject to the Boost Software
// License, Version 1.0. (http://www.boost.org/LICENSE_1_0.txt)
2005-09-11 14:59:52 +00:00
#include "test.hpp"
#include BOOST_TYPEOF_INCREMENT_REGISTRATION_GROUP()
2005-12-04 19:59:42 +00:00
struct x{};
2005-09-11 14:59:52 +00:00
BOOST_TYPEOF_REGISTER_TYPE(x)
BOOST_STATIC_ASSERT(boost::type_of::test<x*>::value);
BOOST_STATIC_ASSERT(boost::type_of::test<x&>::value);
BOOST_STATIC_ASSERT(boost::type_of::test<x[20]>::value);
BOOST_STATIC_ASSERT(boost::type_of::test<const x>::value);
BOOST_STATIC_ASSERT(boost::type_of::test<volatile x>::value);
BOOST_STATIC_ASSERT(boost::type_of::test<volatile const x>::value);