Boost logo

Boost Users :

From: Jan Boehme (jan.boehme_at_[hidden])
Date: 2007-12-17 05:54:31


Hi,
I encountered problems while trying to serialize hash_maps which use pool
allocators ( gcc: no member 'serialize' ). I had a look into
"boost/serialization/hash_map.hpp" and realized a problem in the declaration
of hash_map in here:

BOOST_STD_EXTENSION_NAMESPACE::hash_map<Key, HashFcn, EqualKey, Allocator>

should be

BOOST_STD_EXTENSION_NAMESPACE::hash_map<Key, Value, HashFcn, EqualKey,
Allocator>

It seems that nobody used the hash_map with more than 4 template parameters
together with boost::serialization before.

It would be nice, if the following changes for
"boost/serialization/hash_map.hpp" would be adopted into the repos.

Cheers, Jan.

--- /boost-trunk/boost/serialization/hash_map.hpp 2007-08-01 09:03:
26.000000000 +0200
+++ /boost/serialization/hash_map.hpp 2007-12-17 11:36:27.000000000 +0100
@@ -33,3 +33,4 @@
     class Archive,
- class Key,
+ class Key,
+ class Value,
     class HashFcn,
@@ -41,3 +42,3 @@
     const BOOST_STD_EXTENSION_NAMESPACE::hash_map<
- Key, HashFcn, EqualKey, Allocator
+ Key, Value, HashFcn, EqualKey, Allocator
> &t,
@@ -48,3 +49,3 @@
         BOOST_STD_EXTENSION_NAMESPACE::hash_map<
- Key, HashFcn, EqualKey, Allocator
+ Key, Value, HashFcn, EqualKey, Allocator
>
@@ -55,3 +56,4 @@
     class Archive,
- class Key,
+ class Key,
+ class Value,
     class HashFcn,
@@ -63,3 +65,3 @@
     BOOST_STD_EXTENSION_NAMESPACE::hash_map<
- Key, HashFcn, EqualKey, Allocator
+ Key, Value, HashFcn, EqualKey, Allocator
> &t,
@@ -70,3 +72,3 @@
         BOOST_STD_EXTENSION_NAMESPACE::hash_map<
- Key, HashFcn, EqualKey, Allocator
+ Key, Value, HashFcn, EqualKey, Allocator
>,
@@ -75,3 +77,3 @@
             BOOST_STD_EXTENSION_NAMESPACE::hash_map<
- Key, HashFcn, EqualKey, Allocator
+ Key, Value, HashFcn, EqualKey, Allocator
>
@@ -85,3 +87,4 @@
     class Archive,
- class Key,
+ class Key,
+ class Value,
     class HashFcn,
@@ -93,3 +96,3 @@
     BOOST_STD_EXTENSION_NAMESPACE::hash_map<
- Key, HashFcn, EqualKey, Allocator
+ Key, Value, HashFcn, EqualKey, Allocator
> &t,



Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net