From 4ecacafc9bf1ca57fd002385e7cf8bbb9eff0078 Mon Sep 17 00:00:00 2001 From: Paolo Carlini Date: Fri, 13 Apr 2007 11:17:21 +0000 Subject: [PATCH] re PR libstdc++/31554 (stable_partition assumes iterator difference type is always ptrdiff_t) 2007-04-13 Paolo Carlini PR libstdc++/31554 * include/bits/stl_algo.h (stable_partition): Convert __buf.size() to _DistanceType. From-SVN: r123783 --- libstdc++-v3/ChangeLog | 6 ++++++ libstdc++-v3/include/bits/stl_algo.h | 3 ++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index 1c78c2e17a0..2b1e5d9269f 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,9 @@ +2007-04-13 Paolo Carlini + + PR libstdc++/31554 + * include/bits/stl_algo.h (stable_partition): Convert __buf.size() + to _DistanceType. + 2007-04-13 Paolo Carlini * include/ext/numeric_traits.h: Do not include . diff --git a/libstdc++-v3/include/bits/stl_algo.h b/libstdc++-v3/include/bits/stl_algo.h index 0496ebf3884..30ffbf0dd15 100644 --- a/libstdc++-v3/include/bits/stl_algo.h +++ b/libstdc++-v3/include/bits/stl_algo.h @@ -2186,7 +2186,8 @@ _GLIBCXX_BEGIN_NAMESPACE(std) return std::__stable_partition_adaptive(__first, __last, __pred, _DistanceType(__buf.requested_size()), - __buf.begin(), __buf.size()); + __buf.begin(), + _DistanceType(__buf.size())); else return std::__inplace_stable_partition(__first, __last, __pred,