mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-01-26 08:24:22 +08:00
[multiple changes]
2005-11-02 Thomas Kho <tkho@ucla.edu> PR libstdc++/23425 * include/bits/stl_vector.h (vector<>::clear): Open code in terms of _Destroy. 2005-11-02 Paolo Carlini <pcarlini@suse.de> * include/bits/vector.tcc (vector<>::_M_fill_assign): Qualify fill_n. From-SVN: r106379
This commit is contained in:
parent
ced61f82af
commit
3d8aa000c3
@ -1,3 +1,13 @@
|
|||||||
|
2005-11-02 Thomas Kho <tkho@ucla.edu>
|
||||||
|
|
||||||
|
PR libstdc++/23425
|
||||||
|
* include/bits/stl_vector.h (vector<>::clear): Open code
|
||||||
|
in terms of _Destroy.
|
||||||
|
|
||||||
|
2005-11-02 Paolo Carlini <pcarlini@suse.de>
|
||||||
|
|
||||||
|
* include/bits/vector.tcc (vector<>::_M_fill_assign): Qualify fill_n.
|
||||||
|
|
||||||
2005-11-01 Paolo Carlini <pcarlini@suse.de>
|
2005-11-01 Paolo Carlini <pcarlini@suse.de>
|
||||||
|
|
||||||
PR libstdc++/24595
|
PR libstdc++/24595
|
||||||
|
@ -742,7 +742,11 @@ namespace _GLIBCXX_STD
|
|||||||
*/
|
*/
|
||||||
void
|
void
|
||||||
clear()
|
clear()
|
||||||
{ erase(begin(), end()); }
|
{
|
||||||
|
std::_Destroy(this->_M_impl._M_start, this->_M_impl._M_finish,
|
||||||
|
_M_get_Tp_allocator());
|
||||||
|
this->_M_impl._M_finish = this->_M_impl._M_start;
|
||||||
|
}
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
/**
|
/**
|
||||||
|
@ -184,7 +184,7 @@ namespace _GLIBCXX_STD
|
|||||||
this->_M_impl._M_finish += __n - size();
|
this->_M_impl._M_finish += __n - size();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
erase(fill_n(begin(), __n, __val), end());
|
erase(std::fill_n(begin(), __n, __val), end());
|
||||||
}
|
}
|
||||||
|
|
||||||
template<typename _Tp, typename _Alloc>
|
template<typename _Tp, typename _Alloc>
|
||||||
|
Loading…
Reference in New Issue
Block a user