Boost logo

Boost :

Subject: [boost] warning in serialization.hpp with g++ 4.1
From: Anton Ivanov (ai_at_[hidden])
Date: 2009-08-28 04:18:23


Hello!
during usage serialization.hpp from boost 1.40 we found such problem:

/usr/local/include/boost/serialization/serialization.hpp: In
instantiation of ‘void
boost::serialization::load_construct_data(Archive&, T*, unsigned int)
[with Archive = boost::archive::text_iarchive, T = std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char> >,
std::pair<std::map<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, report_impl::CollectInfo,
std::less<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > >, std::allocator<std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo> > >, std::vector<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::allocator<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > > >]’:
/usr/local/include/boost/serialization/serialization.hpp:163:
instantiated from ‘void
boost::serialization::load_construct_data_adl(Archive&, T*, unsigned
int) [with Archive = boost::archive::text_iarchive, T = std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char> >,
std::pair<std::map<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, report_impl::CollectInfo,
std::less<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > >, std::allocator<std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo> > >, std::vector<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::allocator<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > > >]’
/usr/local/include/boost/serialization/detail/stack_constructor.hpp:58:
  instantiated from
‘boost::serialization::detail::stack_construct<Archive,
T>::stack_construct(Archive&, unsigned int) [with Archive =
boost::archive::text_iarchive, T = std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char> >,
std::pair<std::map<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, report_impl::CollectInfo,
std::less<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > >, std::allocator<std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo> > >, std::vector<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::allocator<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > > >]’
/usr/local/include/boost/serialization/collections_load_imp.hpp:77:
instantiated from ‘void
boost::serialization::stl::archive_input_map<Archive,
Container>::operator()(Archive&, Container&, unsigned int) [with Archive
= boost::archive::text_iarchive, Container =
std::map<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, std::pair<std::map<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo, std::less<std::basic_string<char,
std::char_traits<char>, std::allocator<char> > >,
std::allocator<std::pair<const std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo> > >, std::vector<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::allocator<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > >, std::less<std::basic_string<char,
std::char_traits<char>, std::allocator<char> > >,
std::allocator<std::pair<const std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::pair<std::map<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, report_impl::CollectInfo,
std::less<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > >, std::allocator<std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo> > >, std::vector<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::allocator<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > > > > >]’
/usr/local/include/boost/serialization/collections_load_imp.hpp:191:
instantiated from ‘void
boost::serialization::stl::load_collection(Archive&, Container&) [with
Archive = boost::archive::text_iarchive, Container =
std::map<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, std::pair<std::map<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo, std::less<std::basic_string<char,
std::char_traits<char>, std::allocator<char> > >,
std::allocator<std::pair<const std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo> > >, std::vector<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::allocator<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > >, std::less<std::basic_string<char,
std::char_traits<char>, std::allocator<char> > >,
std::allocator<std::pair<const std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::pair<std::map<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, report_impl::CollectInfo,
std::less<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > >, std::allocator<std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo> > >, std::vector<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::allocator<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > > > > >, InputFunction =
boost::serialization::stl::archive_input_map<boost::archive::text_iarchive,
std::map<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, std::pair<std::map<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo, std::less<std::basic_string<char,
std::char_traits<char>, std::allocator<char> > >,
std::allocator<std::pair<const std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo> > >, std::vector<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::allocator<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > >, std::less<std::basic_string<char,
std::char_traits<char>, std::allocator<char> > >,
std::allocator<std::pair<const std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::pair<std::map<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, report_impl::CollectInfo,
std::less<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > >, std::allocator<std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo> > >, std::vector<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::allocator<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > > > > > >, R =
boost::serialization::stl::no_reserve_imp<std::map<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::pair<std::map<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, report_impl::CollectInfo,
std::less<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > >, std::allocator<std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo> > >, std::vector<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::allocator<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > >, std::less<std::basic_string<char,
std::char_traits<char>, std::allocator<char> > >,
std::allocator<std::pair<const std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::pair<std::map<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, report_impl::CollectInfo,
std::less<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > >, std::allocator<std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo> > >, std::vector<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::allocator<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > > > > > >]’
/usr/local/include/boost/serialization/map.hpp:50: instantiated from
‘void boost::serialization::load(Archive&, std::map<Key, Type, Compare,
Allocator>&, unsigned int) [with Archive =
boost::archive::text_iarchive, Type =
std::pair<std::map<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, report_impl::CollectInfo,
std::less<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > >, std::allocator<std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo> > >, std::vector<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::allocator<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > >, Key = std::basic_string<char,
std::char_traits<char>, std::allocator<char> >, Compare =
std::less<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > >, Allocator = std::allocator<std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char> >,
std::pair<std::map<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, report_impl::CollectInfo,
std::less<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > >, std::allocator<std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo> > >, std::vector<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::allocator<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > > > >]’
/usr/local/include/boost/serialization/split_free.hpp:58: instantiated
from ‘static void boost::serialization::free_loader<Archive,
T>::invoke(Archive&, T&, unsigned int) [with Archive =
boost::archive::text_iarchive, T = std::map<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::pair<std::map<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, report_impl::CollectInfo,
std::less<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > >, std::allocator<std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo> > >, std::vector<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::allocator<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > >, std::less<std::basic_string<char,
std::char_traits<char>, std::allocator<char> > >,
std::allocator<std::pair<const std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::pair<std::map<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, report_impl::CollectInfo,
std::less<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > >, std::allocator<std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo> > >, std::vector<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::allocator<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > > > > >]’
/usr/local/include/boost/serialization/split_free.hpp:74: instantiated
from ‘void boost::serialization::split_free(Archive&, T&, unsigned int)
[with Archive = boost::archive::text_iarchive, T =
std::map<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, std::pair<std::map<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo, std::less<std::basic_string<char,
std::char_traits<char>, std::allocator<char> > >,
std::allocator<std::pair<const std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo> > >, std::vector<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::allocator<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > >, std::less<std::basic_string<char,
std::char_traits<char>, std::allocator<char> > >,
std::allocator<std::pair<const std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::pair<std::map<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, report_impl::CollectInfo,
std::less<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > >, std::allocator<std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo> > >, std::vector<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::allocator<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > > > > >]’
/usr/local/include/boost/serialization/map.hpp:70: instantiated from
‘void boost::serialization::serialize(Archive&, std::map<Key, Type,
Compare, Allocator>&, unsigned int) [with Archive =
boost::archive::text_iarchive, Type =
std::pair<std::map<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, report_impl::CollectInfo,
std::less<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > >, std::allocator<std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo> > >, std::vector<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::allocator<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > >, Key = std::basic_string<char,
std::char_traits<char>, std::allocator<char> >, Compare =
std::less<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > >, Allocator = std::allocator<std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char> >,
std::pair<std::map<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, report_impl::CollectInfo,
std::less<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > >, std::allocator<std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo> > >, std::vector<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::allocator<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > > > >]’
/usr/local/include/boost/serialization/serialization.hpp:133:
instantiated from ‘void boost::serialization::serialize_adl(Archive&,
T&, unsigned int) [with Archive = boost::archive::text_iarchive, T =
std::map<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, std::pair<std::map<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo, std::less<std::basic_string<char,
std::char_traits<char>, std::allocator<char> > >,
std::allocator<std::pair<const std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo> > >, std::vector<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::allocator<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > >, std::less<std::basic_string<char,
std::char_traits<char>, std::allocator<char> > >,
std::allocator<std::pair<const std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::pair<std::map<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, report_impl::CollectInfo,
std::less<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > >, std::allocator<std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo> > >, std::vector<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::allocator<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > > > > >]’
/usr/local/include/boost/archive/detail/iserializer.hpp:170:
instantiated from ‘void boost::archive::detail::iserializer<Archive,
T>::load_object_data(boost::archive::detail::basic_iarchive&, void*,
unsigned int) const [with Archive = boost::archive::text_iarchive, T =
std::map<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, std::pair<std::map<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo, std::less<std::basic_string<char,
std::char_traits<char>, std::allocator<char> > >,
std::allocator<std::pair<const std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo> > >, std::vector<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::allocator<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > >, std::less<std::basic_string<char,
std::char_traits<char>, std::allocator<char> > >,
std::allocator<std::pair<const std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::pair<std::map<std::basic_string<char, std::char_traits<char>,
std::allocator<char> >, report_impl::CollectInfo,
std::less<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > >, std::allocator<std::pair<const
std::basic_string<char, std::char_traits<char>, std::allocator<char> >,
report_impl::CollectInfo> > >, std::vector<std::basic_string<char,
std::char_traits<char>, std::allocator<char> >,
std::allocator<std::basic_string<char, std::char_traits<char>,
std::allocator<char> > > > > > > >]’

/usr/local/include/boost/serialization/serialization.hpp:94: warning:
unused parameter ‘ar’

Patch to fix this warning attached.

-- 
Yours sincerely,
Anton Ivanov (ai_at_[hidden])



Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk