Re: [Boost-bugs] [Boost C++ Libraries] #3529: boost::interprocess::map can't find() elements which exist in the map

Subject: Re: [Boost-bugs] [Boost C++ Libraries] #3529: boost::interprocess::map can't find() elements which exist in the map
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2009-10-16 19:59:33


#3529: boost::interprocess::map can't find() elements which exist in the map
---------------------------+------------------------------------------------
  Reporter: anonymous | Owner:
      Type: Bugs | Status: closed
 Milestone: Boost 1.41.0 | Component: None
   Version: Boost 1.40.0 | Severity: Problem
Resolution: invalid | Keywords:
---------------------------+------------------------------------------------
Changes (by steven_watanabe):

  * status: new => closed
  * resolution: => invalid

Comment:

 Your comparison operator is not quite right.
 It should be

 {{{
 bool operator<(const RouteKey& _o) const {
     return (this->tv_sec < _o.tv_sec ||
             (this->tv_sec == _o.tv_sec && (this->tv_usec < _o.tv_usec ||
             (this->tv_usec == _o.tv_usec && this->pid < _o.pid))
             ));
 }
 }}}

 (warning untested)

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/3529#comment:1>
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