Boost logo

Boost Users :

From: Ted Pederson (ted.pederson_at_[hidden])
Date: 2008-05-09 15:30:41


Yes, newbie error. I had defined a < operator on my struct that is indexed
by multi_index. Once I defined == instead, everything is OK.

On Fri, May 9, 2008 at 9:53 AM, JOAQUIN M. LOPEZ MUÑOZ <joaquin_at_[hidden]>
wrote:

> Hi Ted,
>
> ------------------------------
> *De:* boost-users-bounces_at_[hidden] [
> boost-users-bounces_at_[hidden]] En nombre de Ted Pederson [
> ted.pederson_at_[hidden]]
> *Enviado el:* viernes, 09 de mayo de 2008 18:03
> *Para:* boost-users_at_[hidden]
> *Asunto:* [Boost-users] testing for multi_index equality
> >
> >Is there an easy way to test two multi_index containers for equality, c1
> == c2?
>
> c1 == c2 is defined to be equivalent to c1.get<0>()==c2.get<0>(), which
> is defined if the first index of the container is of type ordered,
> sequenced or
> random access; in all these cases the expression is in fact equivalent to
>
> c1.size()==c2.size()&&std::equal(c1.begin(),c1.end(),c2.begin());
>
> Is this not what you had in mind?
>
> Joaquín M López Muñoz
> Telefónica, Investigación y Desarrollo
>
> _______________________________________________
> Boost-users mailing list
> Boost-users_at_[hidden]
> http://lists.boost.org/mailman/listinfo.cgi/boost-users
>



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