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++/49559] [C++0x] stable_sort calls self-move-assignment operator


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

--- Comment #22 from joerg.richter@pdv-fs.de 2011-07-13 15:11:21 UTC ---
Is it possible to fix it for 4.6.2?
Following program is a 4.4 regression (when using -std=gnu++0x):

-------8<---------
#include <cassert>
#include <vector>
#include <algorithm>

using namespace std;

int main( int, char** )
{
  vector<int> v;
  v.push_back( 1 );
  stable_sort( &v, &v+1 );
  assert( v.size() == 1 );
  return 0;
}
-------8<---------

Works with 4.4.1, fails with 4.5 and 4.6


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