Commit 43804767 by Paolo Carlini Committed by Paolo Carlini

stl_algo.h (stable_sort): Uglify the buf variable.

2006-07-30  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_algo.h (stable_sort): Uglify the buf variable.
	* include/bits/stl_tempbuf.h (_Temporary_buffer<>::
	_M_initialize_buffer): Uglify the val parameter.

From-SVN: r115820
parent 56ee081b
2006-07-30 Paolo Carlini <pcarlini@suse.de>
* include/bits/stl_algo.h (stable_sort): Uglify the buf variable.
* include/bits/stl_tempbuf.h (_Temporary_buffer<>::
_M_initialize_buffer): Uglify the val parameter.
2006-07-27 Benjamin Kosnik <bkoz@wells.artheist.org> 2006-07-27 Benjamin Kosnik <bkoz@wells.artheist.org>
PR libstdc++/19664 round 3 PR libstdc++/19664 round 3
......
...@@ -3850,13 +3850,13 @@ _GLIBCXX_BEGIN_NAMESPACE(std) ...@@ -3850,13 +3850,13 @@ _GLIBCXX_BEGIN_NAMESPACE(std)
__glibcxx_function_requires(_LessThanComparableConcept<_ValueType>) __glibcxx_function_requires(_LessThanComparableConcept<_ValueType>)
__glibcxx_requires_valid_range(__first, __last); __glibcxx_requires_valid_range(__first, __last);
_Temporary_buffer<_RandomAccessIterator, _ValueType> _Temporary_buffer<_RandomAccessIterator, _ValueType> __buf(__first,
buf(__first, __last); __last);
if (buf.begin() == 0) if (__buf.begin() == 0)
std::__inplace_stable_sort(__first, __last); std::__inplace_stable_sort(__first, __last);
else else
std::__stable_sort_adaptive(__first, __last, buf.begin(), std::__stable_sort_adaptive(__first, __last, __buf.begin(),
_DistanceType(buf.size())); _DistanceType(__buf.size()));
} }
/** /**
...@@ -3894,12 +3894,13 @@ _GLIBCXX_BEGIN_NAMESPACE(std) ...@@ -3894,12 +3894,13 @@ _GLIBCXX_BEGIN_NAMESPACE(std)
_ValueType>) _ValueType>)
__glibcxx_requires_valid_range(__first, __last); __glibcxx_requires_valid_range(__first, __last);
_Temporary_buffer<_RandomAccessIterator, _ValueType> buf(__first, __last); _Temporary_buffer<_RandomAccessIterator, _ValueType> __buf(__first,
if (buf.begin() == 0) __last);
if (__buf.begin() == 0)
std::__inplace_stable_sort(__first, __last, __comp); std::__inplace_stable_sort(__first, __last, __comp);
else else
std::__stable_sort_adaptive(__first, __last, buf.begin(), std::__stable_sort_adaptive(__first, __last, __buf.begin(),
_DistanceType(buf.size()), __comp); _DistanceType(__buf.size()), __comp);
} }
/** /**
......
// Temporary buffer implementation -*- C++ -*- // Temporary buffer implementation -*- C++ -*-
// Copyright (C) 2001, 2002, 2004, 2005 Free Software Foundation, Inc. // Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006
// Free Software Foundation, Inc.
// //
// This file is part of the GNU ISO C++ Library. This library is free // This file is part of the GNU ISO C++ Library. This library is free
// software; you can redistribute it and/or modify it under the // software; you can redistribute it and/or modify it under the
...@@ -93,8 +94,8 @@ _GLIBCXX_BEGIN_NAMESPACE(std) ...@@ -93,8 +94,8 @@ _GLIBCXX_BEGIN_NAMESPACE(std)
_M_initialize_buffer(const _Tp&, __true_type) { } _M_initialize_buffer(const _Tp&, __true_type) { }
void void
_M_initialize_buffer(const _Tp& val, __false_type) _M_initialize_buffer(const _Tp& __val, __false_type)
{ std::uninitialized_fill_n(_M_buffer, _M_len, val); } { std::uninitialized_fill_n(_M_buffer, _M_len, __val); }
public: public:
/// As per Table mumble. /// As per Table mumble.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment