[Boost-bugs] [Boost C++ Libraries] #3566: GCC 4.2 compiler warning in in basic_binary_oarchive.hpp:88

Subject: [Boost-bugs] [Boost C++ Libraries] #3566: GCC 4.2 compiler warning in in basic_binary_oarchive.hpp:88
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2009-10-26 23:38:11


#3566: GCC 4.2 compiler warning in in basic_binary_oarchive.hpp:88
---------------------------------------------------------+------------------
 Reporter: Thomas T. <boost-trac@…> | Owner: ramey
     Type: Bugs | Status: new
Milestone: Boost 1.41.0 | Component: serialization
  Version: Boost 1.40.0 | Severity: Problem
 Keywords: |
---------------------------------------------------------+------------------
 Compiling our project with boost 1.40 on GCC 4.2 on OSX Snow Leopard with
 Xcode for x86_64 in debug mode produces the following warning for each of
 the translation units:

 /opt/local/include/boost/archive/basic_binary_oarchive.hpp:88: warning:
 comparison between signed and unsigned integer expressions

 This is the affected code (an assert):

     void save_override(const class_id_reference_type & t, int){
         // upto 32K classes
         assert(t.t <=
 boost::integer_traits<boost::uint_least32_t>::const_max);
         const boost::uint_least16_t x = t.t;
         * this->This() << x;
     }

 Since the line where the error appears is the last line of the main
 function I suspect the problem is somehow triggered by destructor code.

 However as the template code error message is so unspecific and I am not
 familiar with the internals of the serialization implementation in boost,
 it is difficult for me to pinpoint what code using
 basic_binary_oarchive.hpp implicitly is causing this. There are several
 places where I have included binary_oarchive.hpp to enable serialization
 support for classes, but I cant track it down further.

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/3566>
Boost C++ Libraries <http://www.boost.org/>
Boost provides free peer-reviewed portable C++ source libraries.

This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:01 UTC