This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug libstdc++/48038] [C++0x] stable_sort problem with C++0x and comparator by value


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48038

--- Comment #14 from Chris Jefferson <chris at bubblescope dot net> 2011-03-09 11:51:24 UTC ---
Ah yes, I see the problem now.

The problem is to do with using move_iterator. When we compare two values which
we dereference from a move_iterator, then we end up "moving" into the
comparator, which breaks things.

Hmm.. to be honest, this seems like a fairly serious practical flaw in
move_iterator, removing most of the practical reasons for it's presence in the
standard.

I'm having a very quick think about the best way to fix this. Will report back
shortly.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]