diff options
author | Paolo Carlini <pcarlini@suse.de> | 2006-09-21 13:39:38 +0000 |
---|---|---|
committer | Paolo Carlini <paolo@gcc.gnu.org> | 2006-09-21 13:39:38 +0000 |
commit | 6c331f73fb06def451c8a60f2409681fe89939c6 (patch) | |
tree | f5bfe11da2ad163850c2f96d24fb0b36ccea0ea2 | |
parent | 552afe9e94581878157fb20732c11ee1c0efa666 (diff) | |
download | gcc-6c331f73fb06def451c8a60f2409681fe89939c6.zip gcc-6c331f73fb06def451c8a60f2409681fe89939c6.tar.gz gcc-6c331f73fb06def451c8a60f2409681fe89939c6.tar.bz2 |
sso_string_base.h (__sso_string_base<>::_M_max_size(), [...]): Use _M_get_allocator.
2006-09-21 Paolo Carlini <pcarlini@suse.de>
* include/ext/sso_string_base.h (__sso_string_base<>::_M_max_size(),
_M_destroy, _M_create): Use _M_get_allocator.
From-SVN: r117111
-rw-r--r-- | libstdc++-v3/ChangeLog | 5 | ||||
-rw-r--r-- | libstdc++-v3/include/ext/sso_string_base.h | 6 |
2 files changed, 8 insertions, 3 deletions
diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index 8d28ea3..ca26e47 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,8 @@ +2006-09-21 Paolo Carlini <pcarlini@suse.de> + + * include/ext/sso_string_base.h (__sso_string_base<>::_M_max_size(), + _M_destroy, _M_create): Use _M_get_allocator. + 2006-09-21 Ben Elliston <bje@au.ibm.com> * crossconfig.m4 (GLIBCXX_CROSSCONFIG): Remove invocations of diff --git a/libstdc++-v3/include/ext/sso_string_base.h b/libstdc++-v3/include/ext/sso_string_base.h index 24cd160..7f7e2b5 100644 --- a/libstdc++-v3/include/ext/sso_string_base.h +++ b/libstdc++-v3/include/ext/sso_string_base.h @@ -137,7 +137,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx) public: size_type _M_max_size() const - { return (_M_dataplus._CharT_alloc_type::max_size() - 1) / 2; } + { return (_M_get_allocator().max_size() - 1) / 2; } _CharT* _M_data() const @@ -225,7 +225,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx) void __sso_string_base<_CharT, _Traits, _Alloc>:: _M_destroy(size_type __size) throw() - { _M_dataplus._CharT_alloc_type::deallocate(_M_data(), __size + 1); } + { _M_get_allocator().deallocate(_M_data(), __size + 1); } template<typename _CharT, typename _Traits, typename _Alloc> void @@ -324,7 +324,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx) // NB: Need an array of char_type[__capacity], plus a terminating // null char_type() element. - return _M_dataplus._CharT_alloc_type::allocate(__capacity + 1); + return _M_get_allocator().allocate(__capacity + 1); } template<typename _CharT, typename _Traits, typename _Alloc> |