Update of /cvsroot/boost/boost/boost/archive/array
In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv23670/array

Modified Files:
        iarchive.hpp oarchive.hpp 
Log Message:
  


Index: iarchive.hpp
===================================================================
RCS file: /cvsroot/boost/boost/boost/archive/array/iarchive.hpp,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- iarchive.hpp        22 Sep 2006 17:56:59 -0000      1.4
+++ iarchive.hpp        11 Dec 2006 06:31:35 -0000      1.5
@@ -14,7 +14,7 @@
 #include <boost/serialization/array.hpp>
 #include <boost/serialization/collection_size_type.hpp>
 #include <boost/serialization/detail/get_data.hpp>
-#include <boost/type_traits/has_trivial_constructor.hpp>
+#include <boost/type_traits/is_same.hpp>
 #include <boost/mpl/apply.hpp>
 #include <boost/mpl/bool.hpp>
 #include <boost/pfto.hpp>
@@ -94,9 +94,11 @@
   template<class ValueType, class Allocator>
   void load_override(std::vector<ValueType,Allocator> &x, unsigned int version)
   {
-    typedef typename mpl::apply1<
+    typedef typename mpl::and_<
+      mpl::not_<is_same<ValueType,bool> >,
+      mpl::apply1<
         BOOST_DEDUCED_TYPENAME Archive::use_array_optimization
-      , ValueType
+      , ValueType>
     >::type use_optimized;
     load_optimized(x,version, use_optimized() );   
   }

Index: oarchive.hpp
===================================================================
RCS file: /cvsroot/boost/boost/boost/archive/array/oarchive.hpp,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- oarchive.hpp        22 Sep 2006 17:56:59 -0000      1.4
+++ oarchive.hpp        11 Dec 2006 06:31:35 -0000      1.5
@@ -14,6 +14,7 @@
 #include <boost/serialization/nvp.hpp>
 #include <boost/serialization/detail/get_data.hpp>
 #include <boost/type_traits/remove_const.hpp>
+#include <boost/type_traits/is_same.hpp>
 #include <boost/mpl/apply.hpp>
 #include <boost/mpl/bool.hpp>
 #include <boost/pfto.hpp>
@@ -90,12 +91,16 @@
   template<class ValueType, class Allocator>
   void save_override(std::vector<ValueType,Allocator> const &x, unsigned int 
version)
   {
-    typedef typename mpl::apply1<
+    typedef BOOST_DEDUCED_TYPENAME remove_const<ValueType>::type value_type;
+    typedef typename mpl::and_<
+      mpl::not_<is_same<value_type,bool> >,
+      mpl::apply1<
         BOOST_DEDUCED_TYPENAME Archive::use_array_optimization
-      , BOOST_DEDUCED_TYPENAME remove_const<ValueType>::type
+      , value_type>
     >::type use_optimized;
     save_optimized(x,version,use_optimized() );   
   }
+
   
   
   // dispatch saving of arrays to the optimized version where supported


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Boost-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/boost-cvs

Reply via email to