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++/41351] std::rotate on RAI does not conform to ISO complexity requirement



------- Comment #5 from chris at bubblescope dot net  2009-09-14 17:00 -------
You cannot assume the elements you are sorting have a default constructor. You
can however certainly use a separate array of indices, and then swap at the
end, so I withdraw that comment. However, this also only complicates the
problem, as it suggests we should also fix stable_partition.

A long time ago I tried improving the standard library to use whichever of swap
or copy was more efficent, and ended up effectively reinventing rvalue
references using template wrappers.

Given any patches would only be in a new version of gcc, as this is not a
regression, as we haw never done it "properly", would you be happy instead
using the c++0x support in those new compiler?


-- 


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


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