Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r85954 - in trunk: boost boost/multi_index boost/multi_index/detail libs/multi_index/test
From: steveire_at_[hidden]
Date: 2013-09-26 09:04:38


Author: skelly
Date: 2013-09-26 09:04:38 EDT (Thu, 26 Sep 2013)
New Revision: 85954
URL: http://svn.boost.org/trac/boost/changeset/85954

Log:
MultiIndex: Remove obsolete prevent_eti workaround.

It was previously provided for old MSVC.

Deleted:
   trunk/boost/multi_index/detail/prevent_eti.hpp
Text files modified:
   trunk/boost/multi_index/composite_key.hpp | 8 ++------
   trunk/boost/multi_index/detail/auto_space.hpp | 8 ++------
   trunk/boost/multi_index/detail/bucket_array.hpp | 8 ++------
   trunk/boost/multi_index/detail/copy_map.hpp | 8 ++------
   trunk/boost/multi_index/detail/hash_index_node.hpp | 23 +++++------------------
   trunk/boost/multi_index/detail/iter_adaptor.hpp | 8 ++------
   trunk/boost/multi_index/detail/ord_index_node.hpp | 28 ++++++----------------------
   /dev/null | 37 -------------------------------------
   trunk/boost/multi_index/detail/rnd_index_loader.hpp | 8 ++------
   trunk/boost/multi_index/detail/rnd_index_node.hpp | 28 ++++++----------------------
   trunk/boost/multi_index/detail/rnd_index_ptr_array.hpp | 13 +++----------
   trunk/boost/multi_index/detail/seq_index_node.hpp | 23 +++++------------------
   trunk/boost/multi_index_container.hpp | 20 ++++----------------
   trunk/libs/multi_index/test/test_safe_mode.cpp | 5 +----
   14 files changed, 42 insertions(+), 183 deletions(-)

Modified: trunk/boost/multi_index/composite_key.hpp
==============================================================================
--- trunk/boost/multi_index/composite_key.hpp Thu Sep 26 09:04:04 2013 (r85953)
+++ trunk/boost/multi_index/composite_key.hpp 2013-09-26 09:04:38 EDT (Thu, 26 Sep 2013) (r85954)
@@ -16,7 +16,6 @@
 #include <boost/config.hpp> /* keep it first to prevent nasty warns in MSVC */
 #include <boost/functional/hash_fwd.hpp>
 #include <boost/multi_index/detail/access_specifier.hpp>
-#include <boost/multi_index/detail/prevent_eti.hpp>
 #include <boost/mpl/eval_if.hpp>
 #include <boost/mpl/identity.hpp>
 #include <boost/mpl/if.hpp>
@@ -114,14 +113,11 @@
 struct nth_key_from_value
 {
   typedef typename CompositeKey::key_extractor_tuple key_extractor_tuple;
- typedef typename prevent_eti<
- tuples::element<N,key_extractor_tuple>,
- typename mpl::eval_if_c<
+ typedef typename mpl::eval_if_c<
       N<tuples::length<key_extractor_tuple>::value,
       tuples::element<N,key_extractor_tuple>,
       mpl::identity<tuples::null_type>
- >::type
- >::type type;
+ >::type type;
 };
 
 /* nth_composite_key_##name<CompositeKey,N>::type yields

Modified: trunk/boost/multi_index/detail/auto_space.hpp
==============================================================================
--- trunk/boost/multi_index/detail/auto_space.hpp Thu Sep 26 09:04:04 2013 (r85953)
+++ trunk/boost/multi_index/detail/auto_space.hpp 2013-09-26 09:04:38 EDT (Thu, 26 Sep 2013) (r85954)
@@ -17,7 +17,6 @@
 #include <algorithm>
 #include <boost/detail/allocator_utilities.hpp>
 #include <boost/multi_index/detail/adl_swap.hpp>
-#include <boost/multi_index/detail/prevent_eti.hpp>
 #include <boost/noncopyable.hpp>
 #include <memory>
 
@@ -46,12 +45,9 @@
 template<typename T,typename Allocator=std::allocator<T> >
 struct auto_space:private noncopyable
 {
- typedef typename prevent_eti<
- Allocator,
- typename boost::detail::allocator::rebind_to<
+ typedef typename boost::detail::allocator::rebind_to<
       Allocator,T
- >::type
- >::type::pointer pointer;
+ >::type::pointer pointer;
 
   explicit auto_space(const Allocator& al=Allocator(),std::size_t n=1):
   al_(al),n_(n),data_(n_?al_.allocate(n_):pointer(0))

Modified: trunk/boost/multi_index/detail/bucket_array.hpp
==============================================================================
--- trunk/boost/multi_index/detail/bucket_array.hpp Thu Sep 26 09:04:04 2013 (r85953)
+++ trunk/boost/multi_index/detail/bucket_array.hpp 2013-09-26 09:04:38 EDT (Thu, 26 Sep 2013) (r85954)
@@ -17,7 +17,6 @@
 #include <algorithm>
 #include <boost/multi_index/detail/auto_space.hpp>
 #include <boost/multi_index/detail/hash_index_node.hpp>
-#include <boost/multi_index/detail/prevent_eti.hpp>
 #include <boost/noncopyable.hpp>
 #include <cstddef>
 #include <limits.h>
@@ -85,15 +84,12 @@
 template<typename Allocator>
 class bucket_array:public bucket_array_base
 {
- typedef typename prevent_eti<
- Allocator,
- hashed_index_node_impl<
+ typedef hashed_index_node_impl<
       typename boost::detail::allocator::rebind_to<
         Allocator,
         char
>::type
- >
- >::type node_impl_type;
+ > node_impl_type;
 
 public:
   typedef typename node_impl_type::pointer pointer;

Modified: trunk/boost/multi_index/detail/copy_map.hpp
==============================================================================
--- trunk/boost/multi_index/detail/copy_map.hpp Thu Sep 26 09:04:04 2013 (r85953)
+++ trunk/boost/multi_index/detail/copy_map.hpp 2013-09-26 09:04:38 EDT (Thu, 26 Sep 2013) (r85954)
@@ -17,7 +17,6 @@
 #include <algorithm>
 #include <boost/detail/no_exceptions_support.hpp>
 #include <boost/multi_index/detail/auto_space.hpp>
-#include <boost/multi_index/detail/prevent_eti.hpp>
 #include <boost/noncopyable.hpp>
 #include <cstddef>
 #include <functional>
@@ -110,11 +109,8 @@
   }
 
 private:
- typedef typename prevent_eti<
- Allocator,
- typename boost::detail::allocator::rebind_to<
- Allocator,Node>::type
- >::type allocator_type;
+ typedef typename boost::detail::allocator::rebind_to<
+ Allocator,Node>::type allocator_type;
   typedef typename allocator_type::pointer allocator_pointer;
 
   allocator_type al_;

Modified: trunk/boost/multi_index/detail/hash_index_node.hpp
==============================================================================
--- trunk/boost/multi_index/detail/hash_index_node.hpp Thu Sep 26 09:04:04 2013 (r85953)
+++ trunk/boost/multi_index/detail/hash_index_node.hpp 2013-09-26 09:04:38 EDT (Thu, 26 Sep 2013) (r85954)
@@ -15,7 +15,6 @@
 
 #include <boost/config.hpp> /* keep it first to prevent nasty warns in MSVC */
 #include <boost/detail/allocator_utilities.hpp>
-#include <boost/multi_index/detail/prevent_eti.hpp>
 #include <functional>
 
 namespace boost{
@@ -29,17 +28,11 @@
 template<typename Allocator>
 struct hashed_index_node_impl
 {
- typedef typename prevent_eti<
- Allocator,
- typename boost::detail::allocator::rebind_to<
+ typedef typename boost::detail::allocator::rebind_to<
       Allocator,hashed_index_node_impl
- >::type
>::type::pointer pointer;
- typedef typename prevent_eti<
- Allocator,
- typename boost::detail::allocator::rebind_to<
+ typedef typename boost::detail::allocator::rebind_to<
       Allocator,hashed_index_node_impl
- >::type
>::type::const_pointer const_pointer;
 
   pointer& next(){return next_;}
@@ -91,25 +84,19 @@
 
 template<typename Super>
 struct hashed_index_node_trampoline:
- prevent_eti<
- Super,
- hashed_index_node_impl<
+ hashed_index_node_impl<
       typename boost::detail::allocator::rebind_to<
         typename Super::allocator_type,
         char
>::type
>
- >::type
 {
- typedef typename prevent_eti<
- Super,
- hashed_index_node_impl<
+ typedef hashed_index_node_impl<
       typename boost::detail::allocator::rebind_to<
         typename Super::allocator_type,
         char
>::type
- >
- >::type impl_type;
+ > impl_type;
 };
 
 template<typename Super>

Modified: trunk/boost/multi_index/detail/iter_adaptor.hpp
==============================================================================
--- trunk/boost/multi_index/detail/iter_adaptor.hpp Thu Sep 26 09:04:04 2013 (r85953)
+++ trunk/boost/multi_index/detail/iter_adaptor.hpp 2013-09-26 09:04:38 EDT (Thu, 26 Sep 2013) (r85954)
@@ -15,7 +15,6 @@
 
 #include <boost/config.hpp> /* keep it first to prevent nasty warns in MSVC */
 #include <boost/mpl/apply.hpp>
-#include <boost/multi_index/detail/prevent_eti.hpp>
 #include <boost/operators.hpp>
 
 namespace boost{
@@ -295,11 +294,8 @@
 {
   typedef iter_adaptor_selector<
     typename Base::iterator_category> selector;
- typedef typename prevent_eti<
- selector,
- typename mpl::apply2<
- selector,Derived,Base>::type
- >::type type;
+ typedef typename mpl::apply2<
+ selector,Derived,Base>::type type;
 };
 
 template<class Derived,class Base>

Modified: trunk/boost/multi_index/detail/ord_index_node.hpp
==============================================================================
--- trunk/boost/multi_index/detail/ord_index_node.hpp Thu Sep 26 09:04:04 2013 (r85953)
+++ trunk/boost/multi_index/detail/ord_index_node.hpp 2013-09-26 09:04:38 EDT (Thu, 26 Sep 2013) (r85954)
@@ -43,7 +43,6 @@
 #include <boost/config.hpp> /* keep it first to prevent nasty warns in MSVC */
 #include <cstddef>
 #include <boost/detail/allocator_utilities.hpp>
-#include <boost/multi_index/detail/prevent_eti.hpp>
 
 #if !defined(BOOST_MULTI_INDEX_DISABLE_COMPRESSED_ORDERED_INDEX_NODES)
 #include <boost/mpl/and.hpp>
@@ -70,19 +69,13 @@
 template<typename Allocator>
 struct ordered_index_node_std_base
 {
- typedef typename prevent_eti<
- Allocator,
- typename boost::detail::allocator::rebind_to<
+ typedef typename boost::detail::allocator::rebind_to<
       Allocator,
       ordered_index_node_impl<Allocator>
- >::type
>::type::pointer pointer;
- typedef typename prevent_eti<
- Allocator,
- typename boost::detail::allocator::rebind_to<
+ typedef typename boost::detail::allocator::rebind_to<
       Allocator,
       ordered_index_node_impl<Allocator>
- >::type
>::type::const_pointer const_pointer;
   typedef ordered_index_color& color_ref;
   typedef pointer& parent_ref;
@@ -216,12 +209,9 @@
     !(has_uintptr_type::value)||
     (alignment_of<ordered_index_node_compressed_base<Allocator> >::value%2)||
     !(is_same<
- typename prevent_eti<
- Allocator,
- typename boost::detail::allocator::rebind_to<
+ typename boost::detail::allocator::rebind_to<
           Allocator,
           ordered_index_node_impl<Allocator>
- >::type
>::type::pointer,
       ordered_index_node_impl<Allocator>*>::value),
     ordered_index_node_std_base<Allocator>,
@@ -557,25 +547,19 @@
 
 template<typename Super>
 struct ordered_index_node_trampoline:
- prevent_eti<
- Super,
- ordered_index_node_impl<
+ ordered_index_node_impl<
       typename boost::detail::allocator::rebind_to<
         typename Super::allocator_type,
         char
>::type
>
- >::type
 {
- typedef typename prevent_eti<
- Super,
- ordered_index_node_impl<
+ typedef ordered_index_node_impl<
       typename boost::detail::allocator::rebind_to<
         typename Super::allocator_type,
         char
>::type
- >
- >::type impl_type;
+ > impl_type;
 };
 
 template<typename Super>

Deleted: trunk/boost/multi_index/detail/prevent_eti.hpp
==============================================================================
--- trunk/boost/multi_index/detail/prevent_eti.hpp 2013-09-26 09:04:38 EDT (Thu, 26 Sep 2013) (r85953)
+++ /dev/null 00:00:00 1970 (deleted)
@@ -1,37 +0,0 @@
-/* Copyright 2003-2008 Joaquin M Lopez Munoz.
- * Distributed under the Boost Software License, Version 1.0.
- * (See accompanying file LICENSE_1_0.txt or copy at
- * http://www.boost.org/LICENSE_1_0.txt)
- *
- * See http://www.boost.org/libs/multi_index for library home page.
- */
-
-#ifndef BOOST_MULTI_INDEX_DETAIL_PREVENT_ETI_HPP
-#define BOOST_MULTI_INDEX_DETAIL_PREVENT_ETI_HPP
-
-#if defined(_MSC_VER)
-#pragma once
-#endif
-
-#include <boost/config.hpp> /* keep it first to prevent nasty warns in MSVC */
-#include <boost/detail/workaround.hpp>
-
-namespace boost{
-
-namespace multi_index{
-
-namespace detail{
-
-template<typename Type,typename Construct>
-struct prevent_eti
-{
- typedef Construct type;
-};
-
-} /* namespace multi_index::detail */
-
-} /* namespace multi_index */
-
-} /* namespace boost */
-
-#endif

Modified: trunk/boost/multi_index/detail/rnd_index_loader.hpp
==============================================================================
--- trunk/boost/multi_index/detail/rnd_index_loader.hpp Thu Sep 26 09:04:04 2013 (r85953)
+++ trunk/boost/multi_index/detail/rnd_index_loader.hpp 2013-09-26 09:04:38 EDT (Thu, 26 Sep 2013) (r85954)
@@ -17,7 +17,6 @@
 #include <algorithm>
 #include <boost/detail/allocator_utilities.hpp>
 #include <boost/multi_index/detail/auto_space.hpp>
-#include <boost/multi_index/detail/prevent_eti.hpp>
 #include <boost/multi_index/detail/rnd_index_ptr_array.hpp>
 #include <boost/noncopyable.hpp>
 #include <cstddef>
@@ -45,15 +44,12 @@
 class random_access_index_loader_base:private noncopyable
 {
 protected:
- typedef typename prevent_eti<
- Allocator,
- random_access_index_node_impl<
+ typedef random_access_index_node_impl<
       typename boost::detail::allocator::rebind_to<
         Allocator,
         char
>::type
- >
- >::type node_impl_type;
+ > node_impl_type;
   typedef typename node_impl_type::pointer node_impl_pointer;
   typedef random_access_index_ptr_array<Allocator> ptr_array;
 

Modified: trunk/boost/multi_index/detail/rnd_index_node.hpp
==============================================================================
--- trunk/boost/multi_index/detail/rnd_index_node.hpp Thu Sep 26 09:04:04 2013 (r85953)
+++ trunk/boost/multi_index/detail/rnd_index_node.hpp 2013-09-26 09:04:38 EDT (Thu, 26 Sep 2013) (r85954)
@@ -17,7 +17,6 @@
 #include <algorithm>
 #include <boost/detail/allocator_utilities.hpp>
 #include <boost/math/common_factor_rt.hpp>
-#include <boost/multi_index/detail/prevent_eti.hpp>
 #include <cstddef>
 #include <functional>
 
@@ -30,23 +29,14 @@
 template<typename Allocator>
 struct random_access_index_node_impl
 {
- typedef typename prevent_eti<
- Allocator,
- typename boost::detail::allocator::rebind_to<
+ typedef typename boost::detail::allocator::rebind_to<
       Allocator,random_access_index_node_impl
- >::type
>::type::pointer pointer;
- typedef typename prevent_eti<
- Allocator,
- typename boost::detail::allocator::rebind_to<
+ typedef typename boost::detail::allocator::rebind_to<
       Allocator,random_access_index_node_impl
- >::type
>::type::const_pointer const_pointer;
- typedef typename prevent_eti<
- Allocator,
- typename boost::detail::allocator::rebind_to<
+ typedef typename boost::detail::allocator::rebind_to<
       Allocator,pointer
- >::type
>::type::pointer ptr_pointer;
 
   ptr_pointer& up(){return up_;}
@@ -181,25 +171,19 @@
 
 template<typename Super>
 struct random_access_index_node_trampoline:
- prevent_eti<
- Super,
- random_access_index_node_impl<
+ random_access_index_node_impl<
       typename boost::detail::allocator::rebind_to<
         typename Super::allocator_type,
         char
>::type
>
- >::type
 {
- typedef typename prevent_eti<
- Super,
- random_access_index_node_impl<
+ typedef random_access_index_node_impl<
       typename boost::detail::allocator::rebind_to<
         typename Super::allocator_type,
         char
>::type
- >
- >::type impl_type;
+ > impl_type;
 };
 
 template<typename Super>

Modified: trunk/boost/multi_index/detail/rnd_index_ptr_array.hpp
==============================================================================
--- trunk/boost/multi_index/detail/rnd_index_ptr_array.hpp Thu Sep 26 09:04:04 2013 (r85953)
+++ trunk/boost/multi_index/detail/rnd_index_ptr_array.hpp 2013-09-26 09:04:38 EDT (Thu, 26 Sep 2013) (r85954)
@@ -17,7 +17,6 @@
 #include <algorithm>
 #include <boost/detail/allocator_utilities.hpp>
 #include <boost/multi_index/detail/auto_space.hpp>
-#include <boost/multi_index/detail/prevent_eti.hpp>
 #include <boost/multi_index/detail/rnd_index_node.hpp>
 #include <boost/noncopyable.hpp>
 #include <cstddef>
@@ -33,23 +32,17 @@
 template<typename Allocator>
 class random_access_index_ptr_array:private noncopyable
 {
- typedef typename prevent_eti<
- Allocator,
- random_access_index_node_impl<
+ typedef random_access_index_node_impl<
       typename boost::detail::allocator::rebind_to<
         Allocator,
         char
>::type
- >
- >::type node_impl_type;
+ > node_impl_type;
 
 public:
   typedef typename node_impl_type::pointer value_type;
- typedef typename prevent_eti<
- Allocator,
- typename boost::detail::allocator::rebind_to<
+ typedef typename boost::detail::allocator::rebind_to<
       Allocator,value_type
- >::type
>::type::pointer pointer;
 
   random_access_index_ptr_array(

Modified: trunk/boost/multi_index/detail/seq_index_node.hpp
==============================================================================
--- trunk/boost/multi_index/detail/seq_index_node.hpp Thu Sep 26 09:04:04 2013 (r85953)
+++ trunk/boost/multi_index/detail/seq_index_node.hpp 2013-09-26 09:04:38 EDT (Thu, 26 Sep 2013) (r85954)
@@ -16,7 +16,6 @@
 #include <boost/config.hpp> /* keep it first to prevent nasty warns in MSVC */
 #include <algorithm>
 #include <boost/detail/allocator_utilities.hpp>
-#include <boost/multi_index/detail/prevent_eti.hpp>
 
 namespace boost{
 
@@ -29,17 +28,11 @@
 template<typename Allocator>
 struct sequenced_index_node_impl
 {
- typedef typename prevent_eti<
- Allocator,
- typename boost::detail::allocator::rebind_to<
+ typedef typename boost::detail::allocator::rebind_to<
       Allocator,sequenced_index_node_impl
- >::type
>::type::pointer pointer;
- typedef typename prevent_eti<
- Allocator,
- typename boost::detail::allocator::rebind_to<
+ typedef typename boost::detail::allocator::rebind_to<
       Allocator,sequenced_index_node_impl
- >::type
>::type::const_pointer const_pointer;
 
   pointer& prior(){return prior_;}
@@ -136,25 +129,19 @@
 
 template<typename Super>
 struct sequenced_index_node_trampoline:
- prevent_eti<
- Super,
- sequenced_index_node_impl<
+ sequenced_index_node_impl<
       typename boost::detail::allocator::rebind_to<
         typename Super::allocator_type,
         char
>::type
>
- >::type
 {
- typedef typename prevent_eti<
- Super,
- sequenced_index_node_impl<
+ typedef sequenced_index_node_impl<
       typename boost::detail::allocator::rebind_to<
         typename Super::allocator_type,
         char
>::type
- >
- >::type impl_type;
+ > impl_type;
 };
 
 template<typename Super>

Modified: trunk/boost/multi_index_container.hpp
==============================================================================
--- trunk/boost/multi_index_container.hpp Thu Sep 26 09:04:04 2013 (r85953)
+++ trunk/boost/multi_index_container.hpp 2013-09-26 09:04:38 EDT (Thu, 26 Sep 2013) (r85954)
@@ -37,7 +37,6 @@
 #include <boost/multi_index/detail/header_holder.hpp>
 #include <boost/multi_index/detail/has_tag.hpp>
 #include <boost/multi_index/detail/no_duplicate_tags.hpp>
-#include <boost/multi_index/detail/prevent_eti.hpp>
 #include <boost/multi_index/detail/safe_mode.hpp>
 #include <boost/multi_index/detail/scope_guard.hpp>
 #include <boost/multi_index/detail/vartempl_support.hpp>
@@ -90,13 +89,10 @@
         Value,IndexSpecifierList,Allocator>::type
>::type>,
   BOOST_MULTI_INDEX_PRIVATE_IF_MEMBER_TEMPLATE_FRIENDS detail::header_holder<
- typename detail::prevent_eti<
- Allocator,
- typename boost::detail::allocator::rebind_to<
+ typename boost::detail::allocator::rebind_to<
         Allocator,
         typename detail::multi_index_node_type<
           Value,IndexSpecifierList,Allocator>::type
- >::type
>::type::pointer,
     multi_index_container<Value,IndexSpecifierList,Allocator> >,
   public detail::multi_index_base_type<
@@ -131,10 +127,7 @@
   typedef ::boost::base_from_member<
     node_allocator> bfm_allocator;
   typedef detail::header_holder<
- typename detail::prevent_eti<
- Allocator,
- node_allocator
- >::type::pointer,
+ typename node_allocator::pointer,
     multi_index_container> bfm_header;
 
 #if BOOST_WORKAROUND(BOOST_MSVC,<1300)
@@ -1140,18 +1133,13 @@
 template<typename MultiIndexContainer,int N>
 struct nth_index_iterator
 {
- typedef typename detail::prevent_eti<
- nth_index<MultiIndexContainer,N>,
- typename nth_index<MultiIndexContainer,N>::type>::type::iterator type;
+ typedef typename nth_index<MultiIndexContainer,N>::type::iterator type;
 };
 
 template<typename MultiIndexContainer,int N>
 struct nth_index_const_iterator
 {
- typedef typename detail::prevent_eti<
- nth_index<MultiIndexContainer,N>,
- typename nth_index<MultiIndexContainer,N>::type
- >::type::const_iterator type;
+ typedef typename nth_index<MultiIndexContainer,N>::type::const_iterator type;
 };
 
 template<

Modified: trunk/libs/multi_index/test/test_safe_mode.cpp
==============================================================================
--- trunk/libs/multi_index/test/test_safe_mode.cpp Thu Sep 26 09:04:04 2013 (r85953)
+++ trunk/libs/multi_index/test/test_safe_mode.cpp 2013-09-26 09:04:38 EDT (Thu, 26 Sep 2013) (r85954)
@@ -330,10 +330,7 @@
 struct index_policy_base
 {
   typedef MultiIndexContainer container;
- typedef typename
- boost::multi_index::detail::prevent_eti<
- container,
- typename nth_index<container,N>::type>::type index_type;
+ typedef typename nth_index<container,N>::type index_type;
 
   static index_type& index_from_container(container& c){return get<N>(c);}
 };


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk