diff options
author | paolo <paolo@138bc75d-0d04-0410-961f-82ee72b054a4> | 2007-12-11 19:08:26 +0000 |
---|---|---|
committer | paolo <paolo@138bc75d-0d04-0410-961f-82ee72b054a4> | 2007-12-11 19:08:26 +0000 |
commit | 962d818d3f4f9807476bc181608feec7b068fcc1 (patch) | |
tree | 1212618bd275c50c8dd692b834da060b630a3375 /libstdc++-v3/include/bits/stl_bvector.h | |
parent | 15d92c0c76716b1c9249f653aa9c89d002c7d50e (diff) | |
download | gcc-962d818d3f4f9807476bc181608feec7b068fcc1.tar.gz |
2007-12-11 Paolo Carlini <pcarlini@suse.de>
* include/bits/stl_bvector.h (vector<bool>::reserve): Move out of
line...
* include/bits/vector.tcc: ... here.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@130777 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libstdc++-v3/include/bits/stl_bvector.h')
-rw-r--r-- | libstdc++-v3/include/bits/stl_bvector.h | 16 |
1 files changed, 1 insertions, 15 deletions
diff --git a/libstdc++-v3/include/bits/stl_bvector.h b/libstdc++-v3/include/bits/stl_bvector.h index 255e00b793c..045f20378a6 100644 --- a/libstdc++-v3/include/bits/stl_bvector.h +++ b/libstdc++-v3/include/bits/stl_bvector.h @@ -690,21 +690,7 @@ template<typename _Alloc> { _M_range_check(__n); return (*this)[__n]; } void - reserve(size_type __n) - { - if (__n > this->max_size()) - __throw_length_error(__N("vector::reserve")); - if (this->capacity() < __n) - { - _Bit_type* __q = this->_M_allocate(__n); - this->_M_impl._M_finish = _M_copy_aligned(begin(), end(), - iterator(__q, 0)); - this->_M_deallocate(); - this->_M_impl._M_start = iterator(__q, 0); - this->_M_impl._M_end_of_storage = (__q + (__n + int(_S_word_bit) - 1) - / int(_S_word_bit)); - } - } + reserve(size_type __n); reference front() |