id,summary,reporter,owner,description,type,status,milestone,component,version,severity,resolution,keywords,cc 8726,GCC 4.8 warns of variable set but not used,Chris Stylianou ,Robert Ramey,"When compiling with -Wall (GCC 4.8.0) the following warning is raised as an error: {{{ libs/serialization/src/basic_iarchive.cpp: In member function ‘const boost::archive::detail::basic_pointer_iserializer* boost::archive::detail::basic_iarchive_impl::load_pointer(boost::archive::detail::basic_iarchive&, void*&, const boost::archive::detail::basic_pointer_iserializer*, const boost::archive::detail::basic_pointer_iserializer* (*)(const boost::serialization::extended_type_info&))’: libs/serialization/src/basic_iarchive.cpp:455:23: error: variable ‘new_cid’ set but not used [-Werror=unused-but-set-variable] class_id_type new_cid = register_type(bpis_ptr->get_basic_serializer()); }}} ''new_cid'' is only used to perform a BOOST_ASSERT, maybe this could be collapsed into one line? {{{ Index: libs/serialization/src/basic_iarchive.cpp =================================================================== --- libs/serialization/src/basic_iarchive.cpp (revision 84899) +++ libs/serialization/src/basic_iarchive.cpp (working copy) @@ -452,10 +452,9 @@ bpis_ptr = (*finder)(*eti); } BOOST_ASSERT(NULL != bpis_ptr); - class_id_type new_cid = register_type(bpis_ptr->get_basic_serializer()); + BOOST_ASSERT(register_type(bpis_ptr->get_basic_serializer()) == cid); int i = cid; cobject_id_vector[i].bpis_ptr = bpis_ptr; - BOOST_ASSERT(new_cid == cid); } int i = cid; cobject_id & co = cobject_id_vector[i]; }}}",Bugs,closed,Boost 1.54.0,serialization,Boost Development Trunk,Problem,fixed,,