]>
git.proxmox.com Git - ceph.git/blob - ceph/src/boost/libs/container/test/deque_options_test.cpp
1 //////////////////////////////////////////////////////////////////////////////
3 // (C) Copyright Ion Gaztanaga 2004-2013. Distributed under the Boost
4 // Software License, Version 1.0. (See accompanying file
5 // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
7 // See http://www.boost.org/libs/container for documentation.
9 //////////////////////////////////////////////////////////////////////////////
10 #include <boost/container/deque.hpp>
11 #include <boost/core/lightweight_test.hpp>
13 using namespace boost::container
;
15 void test_block_bytes()
17 #if !defined(BOOST_NO_CXX11_TEMPLATE_ALIASES)
18 using options_t
= deque_options_t
< block_bytes
<128u> >;
20 typedef deque_options
< block_bytes
<128u> >::type options_t
;
22 typedef deque
<unsigned short, void, options_t
> deque_t
;
23 BOOST_TEST(deque_t::get_block_size() == 128u/sizeof(unsigned short));
26 void test_block_elements()
28 #if !defined(BOOST_NO_CXX11_TEMPLATE_ALIASES)
29 using options_t
= deque_options_t
< block_size
<64> >;
31 typedef deque_options
< block_size
<64 > >::type options_t
;
33 typedef deque
<unsigned char, void, options_t
> deque_t
;
34 BOOST_TEST(deque_t::get_block_size() == 64U);
40 test_block_elements();
41 return ::boost::report_errors();