From 1e9b4a15eb331383ce6549a0c2a279a1039a7b11 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ion=20Gazta=C3=B1aga?= Date: Thu, 9 May 2019 22:14:57 +0200 Subject: [PATCH] Documentation fixes for options --- include/boost/container/deque.hpp | 2 +- include/boost/container/static_vector.hpp | 9 +++++---- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/include/boost/container/deque.hpp b/include/boost/container/deque.hpp index 4ac7115..be88845 100644 --- a/include/boost/container/deque.hpp +++ b/include/boost/container/deque.hpp @@ -513,7 +513,7 @@ class deque_base //! \tparam T The type of object that is stored in the deque //! \tparam A The allocator used for all internal memory management, use void //! for the default allocator -//! \tparam Options A type produced from \c boost::container::vector_options. +//! \tparam Options A type produced from \c boost::container::deque_options. template #else template diff --git a/include/boost/container/static_vector.hpp b/include/boost/container/static_vector.hpp index 1dfac7d..2c08be8 100644 --- a/include/boost/container/static_vector.hpp +++ b/include/boost/container/static_vector.hpp @@ -35,7 +35,7 @@ namespace boost { namespace container { namespace dtl { -template +template class static_storage_allocator { typedef bool_ throw_on_overflow_t; @@ -87,8 +87,8 @@ class static_storage_allocator { return true; } private: - BOOST_STATIC_ASSERT_MSG(!Alignment || (Alignment & (Alignment-1)) == 0, "Alignment option must be zero or power of two"); - static const std::size_t final_alignment = Alignment ? Alignment : dtl::alignment_of::value; + BOOST_STATIC_ASSERT_MSG(!InplaceAlignment || (InplaceAlignment & (InplaceAlignment-1)) == 0, "Alignment option must be zero or power of two"); + static const std::size_t final_alignment = InplaceAlignment ? InplaceAlignment : dtl::alignment_of::value; typename dtl::aligned_storage::type storage; }; @@ -111,7 +111,7 @@ struct get_static_vector_allocator typedef dtl::static_storage_allocator < T , Capacity - , options_t::alignment + , options_t::inplace_alignment , options_t::throw_on_overflow > type; }; @@ -145,6 +145,7 @@ struct get_static_vector_allocator //! //!@tparam T The type of element that will be stored. //!@tparam Capacity The maximum number of elements static_vector can store, fixed at compile time. +//!@tparam Options A type produced from \c boost::container::static_vector_options. template class static_vector : public vector::type>