gcc/libstdc++-v3/testsuite
Paolo Carlini ec61e852bc basic_string.h (_Rep::_M_is_safe, [...]): New, use througout.
2004-10-25  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/basic_string.h (_Rep::_M_is_safe, _M_check_length,
	_M_move, _M_copy, _M_assign): New, use througout.
	(operator+=(_CharT)): Define in terms of push_back.
	(append(const basic_string&)): Define here, inline, and simplify,
	don't use the full _M_replace_safe.
	(append(size_type, _CharT)): Likewise, don't use _M_replace_aux.
	(push_back): Likewise.
	(assign(const basic_string&)): Define here, inline.
	* include/bits/basic_string.tcc (append(const _CharT* s, size_type):
	Fix: when s points inside the _Rep, upon reallocation (reserve) we
	were copying from deallocated memory.
	(append(const basic_string&, size_type, size_type)): Simplify,
	don't use _M_replace_safe.
	(replace(size_type, size_type, const _CharT*, size_type)): Slightly
	tweak.
	(reserve): Likewise.
	* testsuite/21_strings/basic_string/append/char/2.cc: New.
	* testsuite/21_strings/basic_string/append/char/3.cc: Likewise.
	* testsuite/21_strings/basic_string/append/wchar_t/2.cc: Likewise.
	* testsuite/21_strings/basic_string/append/wchar_t/3.cc: Likewise.

	* testsuite/21_strings/basic_string/assign/char/3.cc: Remove junk.
	* testsuite/21_strings/basic_string/assign/wchar_t/3.cc: Likewise.

From-SVN: r89526
2004-10-25 08:45:04 +00:00
..
17_intro
18_support
19_diagnostics
20_util std_memory.h (__get_temporary_buffer): Don't use INT_MAX... 2004-10-09 08:23:02 +00:00
21_strings basic_string.h (_Rep::_M_is_safe, [...]): New, use througout. 2004-10-25 08:45:04 +00:00
22_locale
23_containers vector.tcc (_M_insert_aux, [...]): Check at the outset that we are not trying to exceed max_size... 2004-10-21 14:53:02 +00:00
24_iterators
25_algorithms
26_numerics
27_io [multiple changes] 2004-10-06 09:06:59 +00:00
backward
config
data
demangle
ext deallocate_global-2.c: s/value_t/value_type/. 2004-10-23 12:41:06 -07:00
lib libstdc++.exp: Update list of undefined functions. 2004-10-07 23:20:42 +00:00
libstdc++-dg
performance list_sort_search.cc: Include <ext/new_allocator.h>. 2004-10-19 08:56:32 +00:00
thread acinclude.m4 (GLIBCXX_ENABLE_THREADS): Set enable_thread. 2004-10-06 22:12:34 +00:00
tr1/6_containers/array array (array): Make safe for zero-sized arrays. 2004-10-22 05:32:16 +00:00
abi_check.cc
Makefile.am acinclude.m4 (GLIBCXX_ENABLE_THREADS): Set enable_thread. 2004-10-06 22:12:34 +00:00
Makefile.in acinclude.m4 (GLIBCXX_ENABLE_THREADS): Set enable_thread. 2004-10-06 22:12:34 +00:00
printnow.c
testsuite_abi.cc
testsuite_abi.h
testsuite_allocator.cc
testsuite_allocator.h vector.tcc (_M_insert_aux, [...]): Check at the outset that we are not trying to exceed max_size... 2004-10-21 14:53:02 +00:00
testsuite_character.h
testsuite_hooks.cc
testsuite_hooks.h
testsuite_io.h
testsuite_performance.h