Commit Graph

8159 Commits

Author SHA1 Message Date
Paolo Carlini
a0d026d943 value.cc: Add test.
2013-12-10  Paolo Carlini  <paolo.carlini@oracle.com>

	* testsuite/20_util/is_base_of/value.cc: Add test.

	* include/std/fstream: Tiny formatting tweak.

From-SVN: r205851
2013-12-10 09:48:50 +00:00
Paolo Carlini
03fd2f6092 re PR libstdc++/59427 (Opening with ios::in | ios::app does not allow appending)
2013-12-09  Paolo Carlini  <paolo.carlini@oracle.com>

	PR libstdc++/59427
	* include/bits/fstream.tcc (basic_filebuf<>::overflow,
	basic_filebuf<>::xsputn): Per lwg/596, ios_base::app implies
	ios_base:out.
	* include/std/fstream (basic_filebuf<>::_M_set_buffer): Likewise.
	* testsuite/27_io/basic_filebuf/sputc/char/59427.cc: New.
	* testsuite/27_io/basic_filebuf/sputn/char/59427.cc: Likewise.

From-SVN: r205837
2013-12-09 23:02:18 +00:00
Renlin Li
c38114079b chi2_quality.cc: Change -DSAMPLES=30000.
libstdc++-v3/

	* testsuite/20_util/hash/chi2_quality.cc: Change -DSAMPLES=30000.

From-SVN: r205810
2013-12-09 17:23:50 +00:00
Jonathan Wakely
da18dcc133 * testsuite/30_threads/async/async.cc: Fix race condition in test.
From-SVN: r205795
2013-12-08 22:18:19 +00:00
Paolo Carlini
ae29d0253f explicit_instantiation.cc: New.
2013-12-08  Paolo Carlini  <paolo.carlini@oracle.com>

	* testsuite/20_util/add_const/requirements/explicit_instantiation.cc:
	New.
	* testsuite/20_util/add_const/value.cc: Likewise.
	* testsuite/20_util/add_cv/requirements/explicit_instantiation.cc:
	Likewise.
	* testsuite/20_util/add_cv/value.cc: Likewise.
	* testsuite/20_util/add_pointer/requirements/explicit_instantiation.cc:
	Likewise.
	* testsuite/20_util/add_pointer/value.cc: Likewise.
	* testsuite/20_util/add_volatile/requirements/
	explicit_instantiation.cc: Likewise.
	* testsuite/20_util/add_volatile/value.cc: Likewise.
	* testsuite/20_util/alignment_of/requirements/
	explicit_instantiation.cc: Likewise.
	* testsuite/20_util/alignment_of/requirements/typedefs.cc: Likewise.
	* testsuite/20_util/alignment_of/value.cc: Likewise.
	* testsuite/20_util/extent/requirements/explicit_instantiation.cc:
	Likewise.
	* testsuite/20_util/extent/requirements/typedefs.cc: Likewise.
	* testsuite/20_util/extent/value.cc: Likewise.
	* testsuite/20_util/has_virtual_destructor/requirements/
	explicit_instantiation.cc: Likewise.
	* testsuite/20_util/has_virtual_destructor/requirements/
	typedefs.cc: Likewise.
	* testsuite/20_util/has_virtual_destructor/value.cc: Likewise.
	* testsuite/20_util/is_abstract/requirements/explicit_instantiation.cc:
 	Likewise.
	* testsuite/20_util/is_abstract/requirements/typedefs.cc: Likewise.
	* testsuite/20_util/is_abstract/value.cc: Likewise.
	* testsuite/20_util/is_arithmetic/requirements/
	explicit_instantiation.cc: Likewise.
	* testsuite/20_util/is_arithmetic/requirements/typedefs.cc: Likewise.
	* testsuite/20_util/is_arithmetic/value.cc: Likewise.
	* testsuite/20_util/is_array/requirements/explicit_instantiation.cc:
	Likewise.
	* testsuite/20_util/is_array/requirements/typedefs.cc: Likewise.
	* testsuite/20_util/is_array/value.cc: Likewise.
	* testsuite/20_util/is_base_of/requirements/explicit_instantiation.cc:
	Likewise.
	* testsuite/20_util/is_base_of/requirements/typedefs.cc: Likewise.
	* testsuite/20_util/is_base_of/value.cc: Likewise.
	* testsuite/20_util/is_class/requirements/explicit_instantiation.cc:
	Likewise.
	* testsuite/20_util/is_class/requirements/typedefs.cc: Likewise.
	* testsuite/20_util/is_class/value.cc: Likewise.
	* testsuite/20_util/is_const/requirements/explicit_instantiation.cc:
	Likewise.
	* testsuite/20_util/is_const/requirements/typedefs.cc: Likewise.
	* testsuite/20_util/is_const/value.cc: Likewise.
	* testsuite/20_util/is_empty/requirements/explicit_instantiation.cc:
	Likewise.
	* testsuite/20_util/is_empty/requirements/typedefs.cc: Likewise.
	* testsuite/20_util/is_empty/value.cc: Likewise.
	* testsuite/20_util/is_enum/requirements/explicit_instantiation.cc:
	Likewise.
	* testsuite/20_util/is_enum/requirements/typedefs.cc
	* testsuite/20_util/is_enum/value.cc: Likewise.
	* testsuite/20_util/is_pointer/requirements/explicit_instantiation.cc
	* testsuite/20_util/is_pointer/value.cc: Likewise.
	* testsuite/20_util/is_polymorphic/requirements/
	explicit_instantiation.cc: Likewise.
	* testsuite/20_util/is_polymorphic/requirements/typedefs.cc: Likewise.
	* testsuite/20_util/is_polymorphic/value.cc: Likewise.
	* testsuite/20_util/is_same/requirements/explicit_instantiation.cc
	* testsuite/20_util/is_same/requirements/typedefs.cc: Likewise.
	* testsuite/20_util/is_same/value.cc: Likewise.
	* testsuite/20_util/is_union/requirements/
	explicit_instantiation.cc: Likewise.
	* testsuite/20_util/is_union/requirements/typedefs.cc: Likewise.
	* testsuite/20_util/is_union/value.cc: Likewise.
	* testsuite/20_util/is_void/requirements/explicit_instantiation.cc
	* testsuite/20_util/is_void/requirements/typedefs.cc: Likewise.
	* testsuite/20_util/is_void/value.cc: Likewise.
	* testsuite/20_util/is_volatile/requirements/
	explicit_instantiation.cc: Likewise.
	* testsuite/20_util/is_volatile/requirements/typedefs.cc: Likewise.
	* testsuite/20_util/is_volatile/value.cc: Likewise.
	* testsuite/20_util/rank/requirements/explicit_instantiation.cc:
	Likewise.
	* testsuite/20_util/rank/requirements/typedefs.cc: Likewise.
	* testsuite/20_util/rank/value.cc: Likewise.
	* testsuite/20_util/remove_all_extents/requirements/
	explicit_instantiation.cc: Likewise.
	* testsuite/20_util/remove_all_extents/value.cc: Likewise.
	* testsuite/20_util/remove_const/requirements/
	explicit_instantiation.cc: Likewise.
	* testsuite/20_util/remove_const/value.cc: Likewise.
	* testsuite/20_util/remove_cv/requirements/explicit_instantiation.cc:
	Likewise.
	* testsuite/20_util/remove_cv/value.cc: Likewise.
	* testsuite/20_util/remove_extent/requirements/
	explicit_instantiation.cc: Likewise.
	* testsuite/20_util/remove_extent/value.cc: Likewise.
	* testsuite/20_util/remove_pointer/requirements/
	explicit_instantiation.cc: Likewise.
	* testsuite/20_util/remove_pointer/value.cc: Likewise.
	* testsuite/20_util/remove_volatile/requirements/
	explicit_instantiation.cc: Likewise.
	* testsuite/20_util/remove_volatile/value.cc: Likewise.

From-SVN: r205789
2013-12-08 09:44:48 +00:00
Paolo Carlini
44916fe15f testsuite_tr1.h (test_category, [...]): constexpr in c++11 mode.
2013-12-06  Paolo Carlini  <paolo.carlini@oracle.com>

	* testsuite/util/testsuite_tr1.h (test_category, test_property,
	test_relationship): constexpr in c++11 mode.
	* testsuite/20_util/add_lvalue_reference/value.cc: Use static_assert
	and change to dg-do compile testcase.
	* testsuite/20_util/add_rvalue_reference/value.cc: Likewise.
	* testsuite/20_util/aligned_storage/value.cc: Likewise.
	* testsuite/20_util/has_trivial_copy_assign/value.cc: Likewise.
	* testsuite/20_util/has_trivial_copy_constructor/value.cc: Likewise.
	* testsuite/20_util/has_trivial_default_constructor/value.cc: Likewise.
	* testsuite/20_util/is_compound/value.cc: Likewise.
	* testsuite/20_util/is_constructible/value.cc: Likewise.
	* testsuite/20_util/is_convertible/value.cc: Likewise.
	* testsuite/20_util/is_copy_assignable/value.cc: Likewise.
	* testsuite/20_util/is_copy_constructible/value.cc: Likewise.
	* testsuite/20_util/is_floating_point/value.cc: Likewise.
	* testsuite/20_util/is_function/value.cc: Likewise.
	* testsuite/20_util/is_fundamental/value.cc: Likewise.
	* testsuite/20_util/is_integral/value.cc: Likewise.
	* testsuite/20_util/is_literal_type/value.cc: Likewise.
	* testsuite/20_util/is_lvalue_reference/value.cc: Likewise.
	* testsuite/20_util/is_member_function_pointer/value.cc: Likewise.
	* testsuite/20_util/is_member_object_pointer/value.cc: Likewise.
	* testsuite/20_util/is_member_pointer/value.cc: Likewise.
	* testsuite/20_util/is_move_assignable/value.cc: Likewise.
	* testsuite/20_util/is_move_constructible/value.cc: Likewise.
	* testsuite/20_util/is_nothrow_assignable/value.cc: Likewise.
	* testsuite/20_util/is_nothrow_constructible/value.cc: Likewise.
	* testsuite/20_util/is_nothrow_copy_assignable/value.cc: Likewise.
	* testsuite/20_util/is_nothrow_copy_constructible/value.cc: Likewise.
	* testsuite/20_util/is_nothrow_default_constructible/value.cc: Likewise.
	* testsuite/20_util/is_nothrow_move_assignable/value.cc: Likewise.
	* testsuite/20_util/is_nothrow_move_constructible/value.cc: Likewise.
	* testsuite/20_util/is_null_pointer/value.cc: Likewise.
	* testsuite/20_util/is_object/value.cc: Likewise.
	* testsuite/20_util/is_pod/value.cc: Likewise.
	* testsuite/20_util/is_reference/value.cc: Likewise.
	* testsuite/20_util/is_rvalue_reference/value.cc: Likewise.
	* testsuite/20_util/is_scalar/value.cc: Likewise.
	* testsuite/20_util/is_signed/value.cc: Likewise.
	* testsuite/20_util/is_standard_layout/value.cc: Likewise.
	* testsuite/20_util/is_trivial/value.cc: Likewise.
	* testsuite/20_util/is_trivially_destructible/value.cc: Likewise.
	* testsuite/20_util/is_unsigned/value.cc: Likewise.
	* testsuite/20_util/make_signed/requirements/typedefs-2.cc: Likewise.
	* testsuite/20_util/make_unsigned/requirements/typedefs-1.cc: Likewise.
	* testsuite/20_util/make_unsigned/requirements/typedefs-2.cc: Likewise.
	* testsuite/20_util/remove_reference/value.cc: Likewise.

From-SVN: r205766
2013-12-06 23:08:41 +00:00
Jonathan Wakely
a566cb5e81 fstream (basic_filebuf::open): Use preformatted text for table in Doxygen comment.
* include/std/fstream (basic_filebuf::open): Use preformatted text
	for table in Doxygen comment.

From-SVN: r205631
2013-12-03 12:58:15 +00:00
Tim Shen
fb5a6c6939 regex_compiler.h: Add todo comment.
2013-12-03  Tim Shen  <timshen91@gmail.com>

	* regex_compiler.h: Add todo comment.
	* regex_executor.tcc: Likewise.

From-SVN: r205624
2013-12-03 10:04:32 +00:00
Matthias Klose
be483ee77a exception, [...]: Remove empty dirs.
2013-11-29  Matthias Klose  <doko@ubuntu.com>

        * testsuite/experimental/string_view/requirements/exception,
        testsuite/experimental/string_view/capacity/wchar_t,
        testsuite/experimental/string_view/capacity/char: Remove empty dirs.

From-SVN: r205536
2013-11-29 17:04:30 +00:00
Rainer Orth
0fe530b6f0 Fix ext/random/hypergeometric_distribution/operators/values.cc on Solaris 9
* testsuite/ext/random/hypergeometric_distribution/operators/values.cc:
	Use dg-require-cmath instead.

From-SVN: r205450
2013-11-27 16:15:35 +00:00
Rainer Orth
3745a526d6 Fix ext/random/hypergeometric_distribution/operators/values.cc on Solaris 9
* testsuite/ext/random/hypergeometric_distribution/operators/values.cc
	(test01): Wrap in _GLIBCXX_USE_C99_MATH_TR1.

From-SVN: r205446
2013-11-27 15:15:23 +00:00
François Dumont
2e5189c83a safe_local_iterator.h (_Safe_local_iterator<>): Remove _M_bucket, use same information in normal local_iterator.
2013-11-22  François Dumont  <fdumont@gcc.gnu.org>

	* include/debug/safe_local_iterator.h (_Safe_local_iterator<>):
	Remove _M_bucket, use same information in normal local_iterator.
	(operator==): Remove redundant _M_can_compare check.
	* include/debug/safe_local_iterator.tcc: Adapt.
	* include/debug/unordered_set: Likewise.
	* include/debug/unordered_map: Likewise.

From-SVN: r205289
2013-11-22 20:55:53 +00:00
Jakub Jelinek
4e1a156d8f Makefile.am (check_DEJAGNU_normal_targets): Add 10.
* testsuite/Makefile.am (check_DEJAGNU_normal_targets): Add 10.
	(check-DEJAGNU): Add normal10, run 28_regex/[ab]*
	tests as another separate job.
	* testsuite/Makefile.in: Regenerated.

From-SVN: r205286
2013-11-22 21:38:59 +01:00
Jonathan Wakely
237c8b9d2f re PR libstdc++/59247 (Bootstrap fails due to errors in libstdc++ sources with `--enable-symvers=gnu-versioned-namespace')
PR libstdc++/59247
	* include/bits/c++config (_GLIBCXX_INLINE_VERSION): Declare namespace
	std::experimental::__7 as inline.
	* include/bits/regex.h (_GLIBCXX_BEGIN_NAMESPACE_VERSION): Do not
	enclose namespace __detail.
	* include/bits/regex.tcc (_GLIBCXX_BEGIN_NAMESPACE_VERSION): Likewise.
	* include/std/iomanip (_GLIBCXX_BEGIN_NAMESPACE_VERSION): Likewise.
	* include/ext/pb_ds/tag_and_trait.hpp (detail): Fix comment.
	* testsuite/ext/profile/mutex_extensions_neg.cc: Adjust line number.

From-SVN: r205277
2013-11-22 16:59:25 +00:00
Jonathan Wakely
2dc2114458 acinclude.m4 (libtool_VERSION): Bump.
2013-11-22  Jonathan Wakely  <jwakely.gcc@gmail.com>

	* acinclude.m4 (libtool_VERSION): Bump.
	* configure: Regenerate.
	* doc/xml/manual/abi.xml: Update version information.

From-SVN: r205258
2013-11-22 13:18:42 +00:00
Paolo Carlini
72fd36d76a values.cc: Fix further thinkos.
2013-11-22  Paolo Carlini  <paolo.carlini@oracle.com>

	* testsuite/ext/random/hypergeometric_distribution/operators/
	values.cc: Fix further thinkos.

From-SVN: r205249
2013-11-22 10:19:46 +00:00
Paolo Carlini
8a1c51c49a values.cc: Fix thinkos.
2013-11-22  Paolo Carlini  <paolo.carlini@oracle.com>

	* testsuite/ext/random/hypergeometric_distribution/operators/
	values.cc: Fix thinkos.

From-SVN: r205248
2013-11-22 10:08:39 +00:00
Edward Smith-Rowland
32f9be169c string_view: Rep empty string with unit-length static constexpr string.
2013-11-21  Edward Smith-Rowland  <3dw4rd@verizon.net>

	* include/experimental/string_view: Rep empty string with unit-length
	static constexpr string. Uncomment _GLIBCXX_VISIBILITY. Enforce
	invariant of no nullptr string pointer.
	* include/experimental/string_view.tcc: Ditto.
	* testsuite/experimental/string_view/cons/char/1.cc: data() for empty
	string_view is no longer nullptr.
	* testsuite/experimental/string_view/cons/wchar_t/1.cc: Ditto.
	* testsuite/experimental/string_view/operations/data/char/1.cc: Ditto.
	* testsuite/experimental/string_view/operations/data/wchar_t/1.cc:
	Ditto.

From-SVN: r205213
2013-11-21 12:30:37 +00:00
Edward Smith-Rowland
d2ae7b11b5 Implement __gnu_cxx::hypergeometric_distribution.
2013-11-21  Edward Smith-Rowland  <3dw4rd@verizon.net>

	Implement __gnu_cxx::hypergeometric_distribution.
	* include/ext/random: Add hypergeometric_distribution.
	* include/ext/random.tcc: Add hypergeometric_distribution.
	* testsuite/util/testsuite_random.h (hypergeometric_pdf): New pdf
	for the hypergeometric discreet distribution;
	(lbincoef): New supporting function for binomial coefficients.
	* testsuite/ext/random/hypergeometric_distribution/operators/
	serialize.cc: New.
	* testsuite/ext/random/hypergeometric_distribution/operators/
	equal.cc: New.
	* testsuite/ext/random/hypergeometric_distribution/operators/
	inequal.cc: New.
	* testsuite/ext/random/hypergeometric_distribution/operators/
	values.cc: New.
	* testsuite/ext/random/hypergeometric_distribution/cons/parms.cc: New.
	* testsuite/ext/random/hypergeometric_distribution/cons/default.cc: New.
	* testsuite/ext/random/hypergeometric_distribution/requirements/
	explicit_instantiation/1.cc: New.
	* testsuite/ext/random/hypergeometric_distribution/requirements/
	typedefs.cc: New.

From-SVN: r205212
2013-11-21 12:27:02 +00:00
Jonathan Wakely
f2f08be7ea re PR libstdc++/49204 ([C++0x] remaining issues in <future>)
PR libstdc++/49204
	* include/std/future (__future_base::_State_base): Rename to
	__future_base::_State_baseV2.
	(__future_base::_State_baseV2::~_State_baseV2): Define as defaulted.
	(__future_base::_State_baseV2::_M_run_deferred): Rename to
	_M_complete_async.
	(__future_base::_State_baseV2::_M_has_deferred): Add new virtual.
	(__future_base::_State_baseV2::wait_for): Call _M_has_deferred() to
	test for a deferred function, or call _M_complete_async() to join an
	async thread that has made the shared state ready.
	(__future_base::_State_baseV2::wait_until): Likewise.
	(__future_base::_Async_state_common): Rename to _Async_state_commonV2.
	(__future_base::_Async_state_commonV2::_M_run_deferred): Rename to
	_M_complete_async.
	* src/c++11/compatibility-thread-c++0x.cc (__future_base::_State_base):
	Export old definition.
	(__future_base::_Async_state_common): Likewise.
	* src/c++11/future.cc (__future_base::_State_base::~_State_base):
	Remove.
	* doc/xml/manual/status_cxx2011.xml: Update status.
	* testsuite/30_threads/async/async.cc: Test future_status::timeout
	and future_status::ready.
	* testsuite/30_threads/async/sync.cc: Test future_status::deferred.

From-SVN: r205144
2013-11-20 20:59:19 +00:00
Jonathan Wakely
f8c370af2c re PR c++/59173 (Alias template in partial specialization finds name from primary template)
PR c++/59173
	* include/ext/pointer.h (pointer_traits<>::rebind<>): Add template
	keyword in nested name.

From-SVN: r205114
2013-11-20 13:39:33 +00:00
David Edelsohn
eb7bdcb027 * testsuite/17_intro/static.cc: Ignore AIX TOC reload warnings.
From-SVN: r205087
2013-11-19 23:38:14 -05:00
Jonathan Wakely
3c8bceb13e gnu.ver (_ZNSt11regex_errorC*): Export regex_error constructors.
* config/abi/pre/gnu.ver (_ZNSt11regex_errorC*): Export regex_error
	constructors.
	* testsuite/20_util/addressof/1.cc: Remove { dg-do compile }.
	* testsuite/20_util/allocator_traits/members/destroy.cc: Likewise.
	* testsuite/20_util/allocator_traits/members/select.cc: Likewise. Fix
	failure.
	* testsuite/28_regex/basic_regex/ctors/extended/cstring.cc: Likewise.
	* testsuite/28_regex/init-list.cc: Likewise.
	* testsuite/28_regex/regex_error/regex_error.cc: Likewise.
	* testsuite/28_regex/sub_match/length.cc: Likewise. Add main.
	* testsuite/28_regex/sub_match/cast_char.cc: Likewise. Fix test.
	* testsuite/28_regex/sub_match/cast_wchar_t.cc: Likewise.
	* testsuite/tr1/7_regular_expressions/regex/cons/char/
	c_string_extended.cc: Delete.

From-SVN: r205063
2013-11-19 23:22:26 +00:00
Jonathan Wakely
50875e80e1 noexcept.cc: Change to compile-only test.
* testsuite/23_containers/forward_list/allocator/noexcept.cc: Change
	to compile-only test. Adjust swap overload to handle rebound
	allocators.
	* testsuite/23_containers/map/allocator/noexcept.cc: Likewise.
	* testsuite/23_containers/multimap/allocator/noexcept.cc: Likewise.
	* testsuite/23_containers/multiset/allocator/noexcept.cc: Likewise.
	* testsuite/23_containers/set/allocator/noexcept.cc: Likewise.
	* testsuite/23_containers/unordered_map/allocator/noexcept.cc:
	Likewise.
	* testsuite/23_containers/unordered_multimap/allocator/noexcept.cc:
	Likewise.
	* testsuite/23_containers/unordered_multiset/allocator/noexcept.cc:
	Likewise.
	* testsuite/23_containers/unordered_set/allocator/noexcept.cc:
	Likewise.
	* testsuite/23_containers/vector/allocator/noexcept.cc: Likewise.
	* testsuite/23_containers/vector/allocator/swap.cc: Add elements
	before swapping.

From-SVN: r205056
2013-11-19 22:03:30 +00:00
Paolo Carlini
660dca797a string_view (_S_max_size): Remove.
2013-11-19  Paolo Carlini  <paolo.carlini@oracle.com>

	* include/experimental/string_view (_S_max_size): Remove.
	(basic_string_view<>::max_size): Adjust.
	* testsuite/experimental/string_view/capacity/1.cc: Clean-up.
	* testsuite/experimental/string_view/inserters/pod/10081-out.cc:
	Likewise.

From-SVN: r205033
2013-11-19 15:45:15 +00:00
Jonathan Wakely
04ef64d536 * doc/xml/manual/status_cxx2014.xml: Create new table for TS statuses.
From-SVN: r205029
2013-11-19 14:58:46 +00:00
Jonathan Wakely
ad098ad133 shared_ptr_base.h (_Sp_counted_base<_S_single>): Use non-atomic operations.
* include/bits/shared_ptr_base.h (_Sp_counted_base<_S_single>): Use
	non-atomic operations.
	* testsuite/20_util/shared_ptr/cons/43820_neg.cc: Adjust line number.
	* testsuite/20_util/shared_ptr/cons/void_neg.cc: Likewise.

From-SVN: r204949
2013-11-18 13:52:39 +00:00
Edward Smith-Rowland
abe6cd5d35 I forgot the ChangeLog and a comment fix for my last checkin.
From-SVN: r204912
2013-11-17 01:58:29 +00:00
François Dumont
6c21c6d0f5 55043.cc (equal): Add missing & on rhs parameter.
2013-11-16  François Dumont  <fdumont@gcc.gnu.org>

	* testsuite/23_containers/unordered_set/55043.cc (equal): Add
	missing & on rhs parameter.

From-SVN: r204906
2013-11-16 20:17:50 +00:00
Edward Smith-Rowland
b032ec0d50 Changed reference to Ch21 Strings in comments in experimental/string_view*.
Forgot this in the main patch.  Sorry.

From-SVN: r204903
2013-11-16 18:03:40 +00:00
Edward Smith-Rowland
77cba5af77 Implement N3762 string_view: a non-owning reference to a string.
2013-11-16  Edward Smith-Rowland  <3dw4rd@verizon.net>

	Implement N3762 string_view: a non-owning reference to a string.
	* include/Makefile.am: Add string_view and string_view.tcc.
	* include/Makefile.in: Regenerate.
	* include/experimental/string_view: Implement basic_string_view.
	* include/experimental/string_view.tcc: Implement basic_string_view.
	* testsuite/experimental/string_view/capacity/1.cc: New.
	* testsuite/experimental/string_view/cons/char/1.cc: New.
	* testsuite/experimental/string_view/cons/char/2.cc: New.
	* testsuite/experimental/string_view/cons/char/3.cc: New.
	* testsuite/experimental/string_view/cons/wchar_t/1.cc: New.
	* testsuite/experimental/string_view/cons/wchar_t/2.cc: New.
	* testsuite/experimental/string_view/cons/wchar_t/3.cc: New.
	* testsuite/experimental/string_view/element_access/char/1.cc: New.
	* testsuite/experimental/string_view/element_access/char/2.cc: New.
	* testsuite/experimental/string_view/element_access/char/empty.cc: New.
	* testsuite/experimental/string_view/element_access/char/front_back.cc:
	New.
	* testsuite/experimental/string_view/element_access/wchar_t/1.cc: New.
	* testsuite/experimental/string_view/element_access/wchar_t/2.cc: New.
	* testsuite/experimental/string_view/element_access/wchar_t/empty.cc:
	New.
	* testsuite/experimental/string_view/element_access/wchar_t/
	front_back.cc: New.
	* testsuite/experimental/string_view/include.cc: New.
	* testsuite/experimental/string_view/inserters/char/1.cc: New.
	* testsuite/experimental/string_view/inserters/char/2.cc: New.
	* testsuite/experimental/string_view/inserters/char/3.cc: New.
	* testsuite/experimental/string_view/inserters/pod/10081-out.cc: New.
	* testsuite/experimental/string_view/inserters/wchar_t/1.cc: New.
	* testsuite/experimental/string_view/inserters/wchar_t/2.cc: New.
	* testsuite/experimental/string_view/inserters/wchar_t/3.cc: New.
	* testsuite/experimental/string_view/literals/types.cc: New.
	* testsuite/experimental/string_view/literals/values.cc: New.
	* testsuite/experimental/string_view/modifiers/remove_prefix/char/1.cc:
	New.
	* testsuite/experimental/string_view/modifiers/remove_prefix/wchar_t/
	1.cc: New.
	* testsuite/experimental/string_view/modifiers/remove_suffix/char/1.cc:
	New.
	* testsuite/experimental/string_view/modifiers/remove_suffix/wchar_t/
	1.cc: New.
	* testsuite/experimental/string_view/operations/compare/char/1.cc: New.
	* testsuite/experimental/string_view/operations/compare/char/13650.cc:
	New.
	* testsuite/experimental/string_view/operations/compare/wchar_t/1.cc:
	New.
	* testsuite/experimental/string_view/operations/compare/wchar_t/
	13650.cc: New.
	* testsuite/experimental/string_view/operations/data/char/1.cc: New.
	* testsuite/experimental/string_view/operations/data/wchar_t/1.cc: New.
	* testsuite/experimental/string_view/operations/find/char/1.cc: New.
	* testsuite/experimental/string_view/operations/find/char/2.cc: New.
	* testsuite/experimental/string_view/operations/find/char/3.cc: New.
	* testsuite/experimental/string_view/operations/find/char/4.cc: New.
	* testsuite/experimental/string_view/operations/find/wchar_t/1.cc: New.
	* testsuite/experimental/string_view/operations/find/wchar_t/2.cc: New.
	* testsuite/experimental/string_view/operations/find/wchar_t/3.cc: New.
	* testsuite/experimental/string_view/operations/find/wchar_t/4.cc: New.
	* testsuite/experimental/string_view/operations/rfind/char/1.cc: New.
	* testsuite/experimental/string_view/operations/rfind/char/2.cc: New.
	* testsuite/experimental/string_view/operations/rfind/char/3.cc: New.
	* testsuite/experimental/string_view/operations/rfind/wchar_t/1.cc: New.
	* testsuite/experimental/string_view/operations/rfind/wchar_t/2.cc: New.
	* testsuite/experimental/string_view/operations/rfind/wchar_t/3.cc: New.
	* testsuite/experimental/string_view/operations/substr/char/1.cc: New.
	* testsuite/experimental/string_view/operations/substr/wchar_t/1.cc:
	New.
	* testsuite/experimental/string_view/operators/char/2.cc: New.
	* testsuite/experimental/string_view/operators/wchar_t/2.cc: New.
	* testsuite/experimental/string_view/range_access/char/1.cc: New.
	* testsuite/experimental/string_view/range_access/wchar_t/1.cc: New.
	* testsuite/experimental/string_view/requirements/
	explicit_instantiation/1.cc: New.
	* testsuite/experimental/string_view/requirements/
	explicit_instantiation/char/1.cc: New.
	* testsuite/experimental/string_view/requirements/
	explicit_instantiation/char16_t/1.cc: New.
	* testsuite/experimental/string_view/requirements/
	explicit_instantiation/char32_t/1.cc: New.
	* testsuite/experimental/string_view/requirements/
	explicit_instantiation/wchar_t/1.cc: New.
	* testsuite/experimental/string_view/requirements/typedefs.cc: New.
	* testsuite/experimental/string_view/types/1.cc: New.

From-SVN: r204902
2013-11-16 17:44:48 +00:00
Jonathan Wakely
3aaaa651a9 stl_bvector.h (vector<bool>::emplace_back()): LWG 2187: Define.
* include/bits/stl_bvector.h (vector<bool>::emplace_back()): LWG 2187:
	Define.
	(vector<bool>::emplace()): Likewise.
	* testsuite/23_containers/vector/bool/emplace.cc: New.

From-SVN: r204851
2013-11-15 16:34:06 +00:00
Ondřej Bílka
64e1ab1168 build_hacking.xml: Fix documentation typos.
2013-11-15  Ondřej Bílka <neleai@seznam.cz>
	    Jonathan Wakely  <jwakely.gcc@gmail.com>

	* doc/xml/manual/build_hacking.xml: Fix documentation typos.
	* doc/xml/manual/configure.xml: Likewise.
	* include/bits/atomic_base.h: Fix typos in comments.
	* include/bits/random.h: Likewise.
	* include/ext/cast.h: Likewise.
	* libsupc++/cxxabi.h: Likewise.
	* testsuite/ext/pb_ds/example/hash_illegal_resize.cc: Likewise.
	* testsuite/tr1/5_numerical_facilities/special_functions/testcase.h:
	Likewise.
	* testsuite/util/exception/safety.h: Likewise.
	* testsuite/util/testsuite_containers.h: Likewise.
	* testsuite/util/testsuite_hooks.cc: Likewise.

Co-Authored-By: Jonathan Wakely <jwakely.gcc@gmail.com>

From-SVN: r204850
2013-11-15 16:33:59 +00:00
Jonathan Wakely
ff90a89e48 stl_map.h (map): Implement C++11 allocator-aware container requirements.
* include/bits/stl_map.h (map): Implement C++11 allocator-aware
	container requirements.
	* include/bits/stl_multimap.h (multimap): Likewise.
	* include/bits/stl_multiset.h (multiset): Likewise.
	* include/bits/stl_set.h (set): Likewise.
	* include/bits/stl_tree.h (_Rb_tree_node): Use __aligned_buffer and
	add accessors for value.
	(_Rb_tree_iterator, _Rb_tree_const_iterator): Use _Rb_tree_node
	accessors.
	(_Rb_tree): Use allocator_traits and implement support for sets and
	maps the be allocator-aware.
	* include/bits/forward_list.h (_Fwd_list_base::_M_create_node): Do
	not zero-initialize storage buffer.
	* include/bits/hashtable_policy.h (_Hashtable_alloc::_M_allocate_node):
	Likewise.
	* include/bits/stl_vector.h (vector(vector&&, const allocator_type&)):
	Add conditional noexcept specification.
	* doc/xml/manual/status_cxx2011.xml: Update status of containers.
	* testsuite/util/testsuite_allocator.h: Re-indent.
	* testsuite/23_containers/forward_list/allocator/copy.cc: Test
	allocator-extended copy constructor.
	* testsuite/23_containers/unordered_map/allocator/copy.cc: Likewise.
	* testsuite/23_containers/unordered_multimap/allocator/copy.cc:
	Likewise.
	* testsuite/23_containers/unordered_multiset/allocator/copy.cc:
	Likewise.
	* testsuite/23_containers/unordered_set/allocator/copy.cc: Likewise.
	* testsuite/23_containers/vector/allocator/copy.cc: Likewise.
	* testsuite/23_containers/forward_list/allocator/move.cc: New.
	* testsuite/23_containers/unordered_map/allocator/move.cc: New.
	* testsuite/23_containers/unordered_multimap/allocator/move.cc: New.
	* testsuite/23_containers/unordered_multiset/allocator/move.cc: New.
	* testsuite/23_containers/unordered_set/allocator/move.cc: New.
	* testsuite/23_containers/vector/allocator/move.cc: New.
	* testsuite/23_containers/map/allocator/copy.cc: New.
	* testsuite/23_containers/map/allocator/copy_assign.cc: New.
	* testsuite/23_containers/map/allocator/minimal.cc: New.
	* testsuite/23_containers/map/allocator/move.cc: New.
	* testsuite/23_containers/map/allocator/move_assign.cc: New.
	* testsuite/23_containers/map/allocator/noexcept.cc: New.
	* testsuite/23_containers/map/allocator/swap.cc: New.
	* testsuite/23_containers/multimap/allocator/copy.cc: New.
	* testsuite/23_containers/multimap/allocator/copy_assign.cc: New.
	* testsuite/23_containers/multimap/allocator/minimal.cc: New.
	* testsuite/23_containers/multimap/allocator/move.cc: New.
	* testsuite/23_containers/multimap/allocator/move_assign.cc: New.
	* testsuite/23_containers/multimap/allocator/noexcept.cc: New.
	* testsuite/23_containers/multimap/allocator/swap.cc: New.
	* testsuite/23_containers/multiset/allocator/copy.cc: New.
	* testsuite/23_containers/multiset/allocator/copy_assign.cc: New.
	* testsuite/23_containers/multiset/allocator/minimal.cc: New.
	* testsuite/23_containers/multiset/allocator/move.cc: New.
	* testsuite/23_containers/multiset/allocator/move_assign.cc: New.
	* testsuite/23_containers/multiset/allocator/noexcept.cc: New.
	* testsuite/23_containers/multiset/allocator/swap.cc: New.
	* testsuite/23_containers/set/allocator/copy.cc: New.
	* testsuite/23_containers/set/allocator/copy_assign.cc: New.
	* testsuite/23_containers/set/allocator/minimal.cc: New.
	* testsuite/23_containers/set/allocator/move.cc: New.
	* testsuite/23_containers/set/allocator/move_assign.cc: New.
	* testsuite/23_containers/set/allocator/noexcept.cc: New.
	* testsuite/23_containers/set/allocator/swap.cc: New.
	* testsuite/23_containers/vector/requirements/dr438/assign_neg.cc:
	Adjust dg-error line number.
	* testsuite/23_containers/vector/requirements/dr438/
	constructor_1_neg.cc: Likewise.
	* testsuite/23_containers/vector/requirements/dr438/
	constructor_2_neg.cc: Likewise.
	* testsuite/23_containers/vector/requirements/dr438/insert_neg.cc:
	Likewise.

From-SVN: r204848
2013-11-15 15:34:14 +00:00
Ulrich Weigand
b54214fe22 rs6000.h (RS6000_SAVE_AREA): Handle ABI_ELFv2.
gcc/ChangeLog:

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
	    Alan Modra  <amodra@gmail.com>

	* config/rs6000/rs6000.h (RS6000_SAVE_AREA): Handle ABI_ELFv2.
	(RS6000_SAVE_TOC): Remove.
	(RS6000_TOC_SAVE_SLOT): New macro.
	* config/rs6000/rs6000.c (rs6000_parm_offset): New function.
	(rs6000_parm_start): Use it.
	(rs6000_function_arg_advance_1): Likewise.
	(rs6000_emit_prologue): Use RS6000_TOC_SAVE_SLOT.
	(rs6000_emit_epilogue): Likewise.
	(rs6000_call_aix): Likewise.
	(rs6000_output_function_prologue): Do not save/restore r11
	around calling _mcount for ABI_ELFv2.

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
	    Alan Modra  <amodra@gmail.com>

	* config/rs6000/rs6000-protos.h (rs6000_reg_parm_stack_space):
	Add prototype.
	* config/rs6000/rs6000.h (RS6000_REG_SAVE): Remove.
	(REG_PARM_STACK_SPACE): Call rs6000_reg_parm_stack_space.
	* config/rs6000/rs6000.c (rs6000_parm_needs_stack): New function.
	(rs6000_function_parms_need_stack): Likewise.
	(rs6000_reg_parm_stack_space): Likewise.
	(rs6000_function_arg): Do not replace BLKmode by Pmode when
	returning a register argument.

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
	    Michael Gschwind  <mkg@us.ibm.com>

	* config/rs6000/rs6000.h (FP_ARG_MAX_RETURN): New macro.
	(ALTIVEC_ARG_MAX_RETURN): Likewise.
	(FUNCTION_VALUE_REGNO_P): Use them.
	* config/rs6000/rs6000.c (TARGET_RETURN_IN_MSB): Define.
	(rs6000_return_in_msb): New function.
	(rs6000_return_in_memory): Handle ELFv2 homogeneous aggregates.
	Handle aggregates of up to 16 bytes for ELFv2.
	(rs6000_function_value): Handle ELFv2 homogeneous aggregates.

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
	    Michael Gschwind  <mkg@us.ibm.com>

	* config/rs6000/rs6000.h (AGGR_ARG_NUM_REG): Define.
	* config/rs6000/rs6000.c (rs6000_aggregate_candidate): New function.
	(rs6000_discover_homogeneous_aggregate): Likewise.
	(rs6000_function_arg_boundary): Handle homogeneous aggregates.
	(rs6000_function_arg_advance_1): Likewise.
	(rs6000_function_arg): Likewise.
	(rs6000_arg_partial_bytes): Likewise.
	(rs6000_psave_function_arg): Handle BLKmode arguments.

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
	    Michael Gschwind  <mkg@us.ibm.com>

	* config/rs6000/rs6000.h (AGGR_ARG_NUM_REG): Define.
	* config/rs6000/rs6000.c (rs6000_aggregate_candidate): New function.
	(rs6000_discover_homogeneous_aggregate): Likewise.
	(rs6000_function_arg_boundary): Handle homogeneous aggregates.
	(rs6000_function_arg_advance_1): Likewise.
	(rs6000_function_arg): Likewise.
	(rs6000_arg_partial_bytes): Likewise.
	(rs6000_psave_function_arg): Handle BLKmode arguments.

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>

	* config/rs6000/rs6000.c (machine_function): New member
	r2_setup_needed.
	(rs6000_emit_prologue): Set r2_setup_needed if necessary.
	(rs6000_output_mi_thunk): Set r2_setup_needed.
	(rs6000_output_function_prologue): Output global entry point
	prologue and local entry point marker if needed for ABI_ELFv2.
	Output -mprofile-kernel code here.
	(output_function_profiler): Do not output -mprofile-kernel
	code here; moved to rs6000_output_function_prologue.
	(rs6000_file_start): Output ".abiversion 2" for ABI_ELFv2.

	(rs6000_emit_move): Do not handle dot symbols for ABI_ELFv2.
	(rs6000_output_function_entry): Likewise.
	(rs6000_assemble_integer): Likewise.
	(rs6000_elf_encode_section_info): Likewise.
	(rs6000_elf_declare_function_name): Do not create dot symbols
	or .opd section for ABI_ELFv2.

	(rs6000_trampoline_size): Update for ABI_ELFv2 trampolines.
	(rs6000_trampoline_init): Likewise.
	(rs6000_elf_file_end): Call file_end_indicate_exec_stack
	for ABI_ELFv2.

	(rs6000_call_aix): Handle ELFv2 indirect calls.  Do not check
	for function descriptors in ABI_ELFv2.

	* config/rs6000/rs6000.md ("*call_indirect_aix<mode>"): Support
	on ABI_AIX only, not ABI_ELFv2.
	("*call_value_indirect_aix<mode>"): Likewise.
	("*call_indirect_elfv2<mode>"): New pattern.
	("*call_value_indirect_elfv2<mode>"): Likewise.

	* config/rs6000/predicates.md ("symbol_ref_operand"): Do not
	check for function descriptors in ABI_ELFv2.
	("current_file_function_operand"): Likewise.

	* config/rs6000/ppc-asm.h [__powerpc64__ && _CALL_ELF == 2]:
	(toc): Undefine.
	(FUNC_NAME): Define ELFv2 variant.
	(JUMP_TARGET): Likewise.
	(FUNC_START): Likewise.
	(HIDDEN_FUNC): Likewise.
	(FUNC_END): Likeiwse.

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>

	* config.gcc [powerpc*-*-* | rs6000-*-*]: Support --with-abi=elfv1
	and --with-abi=elfv2.
	* config/rs6000/option-defaults.h (OPTION_DEFAULT_SPECS): Add "abi".
	* config/rs6000/rs6000.opt (mabi=elfv1): New option.
	(mabi=elfv2): Likewise.
	* config/rs6000/rs6000-opts.h (enum rs6000_abi): Add ABI_ELFv2.
	* config/rs6000/linux64.h (DEFAULT_ABI): Do not hard-code to AIX_ABI
	if !RS6000_BI_ARCH.
	(ELFv2_ABI_CHECK): New macro.
	(SUBSUBTARGET_OVERRIDE_OPTIONS): Use it to decide whether to set
	rs6000_current_abi to ABI_AIX or ABI_ELFv2.
	(GLIBC_DYNAMIC_LINKER64): Support ELFv2 ld.so version.
	* config/rs6000/rs6000-c.c (rs6000_cpu_cpp_builtins): Predefine
	_CALL_ELF and __STRUCT_PARM_ALIGN__ if appropriate.

	* config/rs6000/rs6000.c (rs6000_debug_reg_global): Handle ABI_ELFv2.
	(debug_stack_info): Likewise.
	(rs6000_file_start): Treat ABI_ELFv2 the same as ABI_AIX.
	(rs6000_legitimize_tls_address): Likewise.
	(rs6000_conditional_register_usage): Likewise.
	(rs6000_emit_move): Likewise.
	(init_cumulative_args): Likewise.
	(rs6000_function_arg_advance_1): Likewise.
	(rs6000_function_arg): Likewise.
	(rs6000_arg_partial_bytes): Likewise.
	(rs6000_output_function_entry): Likewise.
	(rs6000_assemble_integer): Likewise.
	(rs6000_savres_strategy): Likewise.
	(rs6000_stack_info): Likewise.
	(rs6000_function_ok_for_sibcall): Likewise.
	(rs6000_emit_load_toc_table): Likewise.
	(rs6000_savres_routine_name): Likewise.
	(ptr_regno_for_savres): Likewise.
	(rs6000_emit_prologue): Likewise.
	(rs6000_emit_epilogue): Likewise.
	(rs6000_output_function_epilogue): Likewise.
	(output_profile_hook): Likewise.
	(output_function_profiler): Likewise.
	(rs6000_trampoline_size): Likewise.
	(rs6000_trampoline_init): Likewise.
	(rs6000_elf_output_toc_section_asm_op): Likewise.
	(rs6000_elf_encode_section_info): Likewise.
	(rs6000_elf_reloc_rw_mask): Likewise.
	(rs6000_elf_declare_function_name): Likewise.
	(rs6000_function_arg_boundary): Treat ABI_ELFv2 the same as ABI_AIX,
	except that rs6000_compat_align_parm is always assumed false.
	(rs6000_gimplify_va_arg): Likewise.
	(rs6000_call_aix): Update comment.
	(rs6000_sibcall_aix): Likewise.
	* config/rs6000/rs6000.md ("tls_gd_aix<TLSmode:tls_abi_suffix>"):
	Treat ABI_ELFv2 the same as ABI_AIX.
	("*tls_gd_call_aix<TLSmode:tls_abi_suffix>"): Likewise.
	("tls_ld_aix<TLSmode:tls_abi_suffix>"): Likewise.
	("*tls_ld_call_aix<TLSmode:tls_abi_suffix>"): Likewise.
	("load_toc_aix_si"): Likewise.
	("load_toc_aix_di"): Likewise.
	("call"): Likewise.
	("call_value"): Likewise.
	("*call_local_aix<mode>"): Likewise.
	("*call_value_local_aix<mode>"): Likewise.
	("*call_nonlocal_aix<mode>"): Likewise.
	("*call_value_nonlocal_aix<mode>"): Likewise.
	("*call_indirect_aix<mode>"): Likewise.
	("*call_value_indirect_aix<mode>"): Likewise.
	("sibcall"): Likewise.
	("sibcall_value"): Likewise.
	("*sibcall_aix<mode>"): Likewise.
	("*sibcall_value_aix<mode>"): Likewise.
	* config/rs6000/predicates.md ("symbol_ref_operand"): Likewise.
	("current_file_function_operand"): Likewise.

gcc/testsuite/ChangeLog:

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>

	* gcc.target/powerpc/ppc64-abi-1.c (stack_frame_t): Remove
	compiler and linker field if _CALL_ELF == 2.
	* gcc.target/powerpc/ppc64-abi-2.c (stack_frame_t): Likewise.
	* gcc.target/powerpc/ppc64-abi-dfp-1.c (stack_frame_t): Likewise.
	* gcc.dg/stack-usage-1.c (SIZE): Update value for _CALL_ELF == 2.

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>

	* gcc.target/powerpc/ppc64-abi-dfp-1.c (FUNC_START): New macro.
	(WRAPPER): Use it.
	* gcc.target/powerpc/no-r11-1.c: Skip on powerpc_elfv2.
	* gcc.target/powerpc/no-r11-2.c: Skip on powerpc_elfv2.
	* gcc.target/powerpc/no-r11-3.c: Skip on powerpc_elfv2.

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>

	* lib/target-supports.exp (check_effective_target_powerpc_elfv2):
	New function.
	* gcc.target/powerpc/pr57949-1.c: Disable for powerpc_elfv2.
	* gcc.target/powerpc/pr57949-2.c: Likewise.

libgcc/ChangeLog:

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
	    Alan Modra  <amodra@gmail.com>

	* config/rs6000/linux-unwind.h (TOC_SAVE_SLOT): Define.
	(frob_update_context): Use it.

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
	    Alan Modra  <amodra@gmail.com>

	* config/rs6000/tramp.S [__powerpc64__ && _CALL_ELF == 2]:
	(trampoline_initial): Provide ELFv2 variant.
	(__trampoline_setup): Likewise.

	* config/rs6000/linux-unwind.h (frob_update_context): Do not
	check for AIX indirect function call sequence if _CALL_ELF == 2.

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
	    Alan Modra  <amodra@gmail.com>

	* config/rs6000/linux-unwind.h (get_regs): Do not support
	old kernel versions if _CALL_ELF == 2.
	(frob_update_context): Do not support PLT stub variants only
	generated by old linkers if _CALL_ELF == 2.

libitm/ChangeLog:

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>

	* config/powerpc/sjlj.S [__powerpc64__ && _CALL_ELF == 2]:
	(FUNC): Define ELFv2 variant.
	(END): Likewise.
	(HIDDEN): Likewise.
	(CALL): Likewise.
	(BASE): Likewise.
	(LR_SAVE): Likewise.

libstdc++/ChangeLog:

2013-11-14  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>

	* scripts/extract_symvers.in: Ignore <localentry: > fields
	in readelf --symbols output.


Co-Authored-By: Alan Modra <amodra@gmail.com>
Co-Authored-By: Michael Gschwind <mkg@us.ibm.com>

From-SVN: r204808
2013-11-14 18:50:48 +00:00
Jonathan Wakely
8ed13e2757 alloc_traits.h (__allow_copy_cons): Remove.
* include/bits/alloc_traits.h (__allow_copy_cons): Remove.
	(__check_copy_constructible): Likewise.
	* include/bits/unordered_map.h (unordered_map, unordered_multimap):
	Do not derive from __check_copy_constructible.
	* include/bits/unordered_set.h (unordered_set, unordered_multiset):
	Likewise.
	* testsuite/23_containers/unordered_map/55043.cc: It is no longer
	necessary for is_copy_constructible to be correct to use nested
	unordered containers.
	* testsuite/23_containers/unordered_multimap/55043.cc: Likewise.
	* testsuite/23_containers/unordered_set/55043.cc: Likewise.
	* testsuite/23_containers/unordered_multiset/55043.cc: Likewise.

From-SVN: r204790
2013-11-14 12:43:00 +00:00
Marc Glisse
b62c62f4b0 re PR libstdc++/59087 (Issues including complex.h in C++11/1y mode because of C's complex.h)
2013-11-13  Marc Glisse  <marc.glisse@inria.fr>

	PR libstdc++/59087
	* include/ext/pod_char_traits.h: Uglify V, I and S.

From-SVN: r204750
2013-11-13 15:47:04 +00:00
Jonathan Wakely
6162239973 re PR libstdc++/54562 (mutex and condition variable timers)
PR libstdc++/54562
	* include/std/mutex (__timed_mutex_impl::__clock_t): Use
	high_resolution_clock for absolute timeouts, because
	pthread_mutex_timedlock uses CLOCK_REALTIME not CLOCK_MONOTONIC.
	(__timed_mutex_impl::_M_try_lock_for): Use steady_clock for relative
	timeouts as per [thread.req.timing].
	(__timed_mutex_impl::_M_try_lock_until<Clock,Duration>): Convert to
	__clock_t time point instead of using _M_try_lock_for.

From-SVN: r204672
2013-11-11 13:33:48 +00:00
Jonathan Wakely
5275f3e546 re PR libstdc++/58982 (std::vector<std::atomic<int>> vai(10); does not compile anymore)
PR libstdc++/58982
	* include/bits/stl_algobase.h (__copy_move::__copy_m): Use assertion
	to prevent using memmove() on non-assignable types.
	(__copy_move_backward::__copy_move_b): Likewise.
	* include/bits/stl_uninitialized.h (uninitialized_copy
	uninitialized_copy_n, uninitialized_fill, uninitialized_fill_n,
	__uninitialized_default, __uninitialized_default_n): Check for
	assignable as well as trivial.
	* testsuite/20_util/specialized_algorithms/uninitialized_copy/
	58982.cc: New.
	* testsuite/20_util/specialized_algorithms/uninitialized_copy_n/
	58982.cc: New.
	* testsuite/20_util/specialized_algorithms/uninitialized_fill/
	58982.cc: New.
	* testsuite/20_util/specialized_algorithms/uninitialized_fill_n/
	58982.cc: New.
	* testsuite/25_algorithms/copy/58982.cc: New.
	* testsuite/25_algorithms/copy_n/58982.cc: New.

From-SVN: r204615
2013-11-09 12:38:00 +00:00
François Dumont
9fc0e24b6c safe_iterator.h (_BeforeBeginHelper<>::_S_Is): Take only a const safe iterator reference.
2013-11-08  François Dumont  <fdumont@gcc.gnu.org>

	* include/debug/safe_iterator.h (_BeforeBeginHelper<>::_S_Is):
	Take only a const safe iterator reference.
	(_BeforeBeginHelper<>::_S_Is_beginnest): Likewise.
	(__get_distance): Take only one type of iterator.
	(_Safe_iterator<>::_M_valid_range<>): Not template anymore.
	(_Safe_iterator<>::_M_get_sequence()): Return pointer to const
	sequence from a const_iterator and a pointer to sequence from an
	iterator.
	* include/debug/safe_iterator.tcc: Adapt.
	* include/debug/safe_local_iterator.h
	(_Safe_local_iterator<>::_M_valid_range<>): Not template anymore.
	(_Safe_local_iterator<>::_M_get_sequence()): Return pointer to
	const sequence from a const_iterator and a pointer to sequence
	from an iterator.
	* include/debug/safe_local_iterator.tcc: Adapt.
	* include/debug/forward_list
	(_BeforeBeginHelper<std::__debug::forward_list<>>): Adapt.

From-SVN: r204598
2013-11-08 21:03:58 +00:00
Jonathan Wakely
e15c474a34 regex_compiler.h (__detail::__has_contiguous_iter): vector<bool> storage is not contiguous.
* include/bits/regex_compiler.h (__detail::__has_contiguous_iter):
	vector<bool> storage is not contiguous.

From-SVN: r204582
2013-11-08 17:33:31 +00:00
Jonathan Wakely
34d1ff06bf regex_compiler.h (__detail::__compile_nfa): Overload so that std::basic_string<C> and std::vector<C> iterators dispatch to...
* include/bits/regex_compiler.h (__detail::__compile_nfa): Overload
	so that std::basic_string<C> and std::vector<C> iterators dispatch to
	the const C* compiler.

From-SVN: r204574
2013-11-08 14:30:40 +00:00
Jonathan Wakely
bb038ece8f regex_compiler.h (__detail::_AnyMatcher, [...]): Remove redundant _CharT template parameters.
* include/bits/regex_compiler.h (__detail::_AnyMatcher,
	__detail::_CharMatcher, __detail::_BracketMatcher): Remove redundant
	_CharT template parameters.
	* include/bits/regex_compiler.tcc: Likewise.

From-SVN: r204573
2013-11-08 14:30:34 +00:00
Jonathan Wakely
68e69ce27f regex_automaton.h (__detail::_State, [...]): Remove redundant _CharT template parameters.
* include/bits/regex_automaton.h (__detail::_State, __detail::_NFA,
	__detail::_StateSeq): Remove redundant _CharT template parameters.
	* include/bits/regex_automaton.tcc: Likewise.
	* include/bits/regex_compiler.h (__detail::_Compiler): Likewise.
	(__compile_nfa): Add object generator for _Compiler.
	* include/bits/regex_compiler.tcc: Remove _CharT template parameters.
	* include/bits/regex_executor.h: Likewise.
	* include/bits/regex_executor.tcc: Likewise.
	* include/bits/regex.h (basic_regex): Assert char_type matches. Use
	__compile_nfa object generator. Remove _CharT template parameter.

From-SVN: r204572
2013-11-08 14:30:29 +00:00
Jonathan Wakely
7d9d218516 regex_automaton.h (__detail::_State): Split non-dependent parts into new _State_base.
* include/bits/regex_automaton.h (__detail::_State): Split
	non-dependent parts into new _State_base.
	(__detail::_NFA): Likewise for _NFA_base. Use std::move() to avoid
	copies when inserting _MatcherT and _StateT objects.
	* include/bits/regex_automaton.tcc: Move member definitions to base
	class. Qualify dependent names.
	* include/bits/regex_compiler.h (__detail::_Compiler::_M_get_nfa): Make
	non-const and use std::move to avoid copying.
	* include/bits/regex_compiler.tcc: Likewise.
	* include/bits/regex_executor.h (__detail::_Executor::_M_is_word): Use
	array, so past-the-end iterator is valid.

From-SVN: r204571
2013-11-08 14:30:22 +00:00
Jonathan Wakely
f054ff5b7c regex_automaton.h (_S_opcode_word_boundry): Rename to _S_opcode_word_boundary.
* include/bits/regex_automaton.h (_S_opcode_word_boundry): Rename to
	_S_opcode_word_boundary.
	* include/bits/regex_automaton.tcc: Likewise.
	* include/bits/regex_executor.h (__detail::_Executor::_M_word_boundry):
	Rename to _M_word_boundary.
	* include/bits/regex_executor.tcc: Likewise.

From-SVN: r204449
2013-11-06 09:47:51 +00:00
Jonathan Wakely
4457e88ce1 N3655 C++1y TransformationTraits Redux
N3655 C++1y TransformationTraits Redux
	* include/std/type_traits (remove_const_t, remove_volatile_t,
	remove_cv_t, add_const_t, add_volatile_t, add_cv_t, remove_reference_t,
	add_lvalue_reference_t, add_rvalue_reference_t, make_signed_t,
	make_unsigned_t, remove_extent_t, remove_all_extents_t,
	remove_pointer_t, add_pointer_t, aligned_storage_t, decay_t,
	enable_if_t, conditional_t, common_type_t, underlying_type_t,
	result_of_t): Define.
	* doc/xml/manual/status_cxx2014.xml: Update.
	* testsuite/20_util/add_lvalue_reference/requirements/typedefs-3.cc:
	New.
	* testsuite/20_util/add_rvalue_reference/requirements/typedefs-3.cc:
	New.
	* testsuite/20_util/common_type/requirements/typedefs-3.cc: New.
	* testsuite/20_util/conditional/requirements/typedefs-2.cc: New.
	* testsuite/20_util/decay/requirements/typedefs-2.cc: New.
	* testsuite/20_util/enable_if/requirements/typedefs-2.cc: New.
	* testsuite/20_util/make_signed/requirements/typedefs-3.cc: New.
	* testsuite/20_util/make_unsigned/requirements/typedefs-3.cc: New.
	* testsuite/20_util/remove_reference/requirements/typedefs.cc: New.
	* testsuite/20_util/result_of/requirements/typedefs.cc: New.
	* testsuite/20_util/underlying_type/requirements/typedefs-3.cc: New.
	* testsuite/20_util/common_type/requirements/typedefs-2.cc: Change to
	compile-only test.
	* testsuite/20_util/decay/requirements/typedefs.cc: Likewise.
	* testsuite/20_util/make_signed/requirements/typedefs-1.cc: Likewise.
	* testsuite/20_util/declval/requirements/1_neg.cc: Adjust dg-error
	line number.
	* testsuite/20_util/make_signed/requirements/typedefs_neg.cc:
	Likewise.
	* testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc:
	Likewise.

From-SVN: r204426
2013-11-05 22:57:36 +00:00
Jonathan Wakely
ae40b2ffce status_cxx2011.xml: Document aligned_union as missing.
* doc/xml/manual/status_cxx2011.xml: Document aligned_union as
	missing.

From-SVN: r204416
2013-11-05 19:59:21 +00:00
Jonathan Wakely
b1705a6388 optional: Use __and_<> and __not_<> in conditions.
2013-11-05  Jonathan Wakely  <jwakely.gcc@gmail.com>
	    Paolo Carlini  <paolo.carlini@oracle.com>

	* include/experimental/optional: Use __and_<> and __not_<> in
	conditions. Style fixes.
	(__constexpr_addressof, swap): Make inline.
	* testsuite/experimental/optional/cons/copy.cc: Adjust constants for
	32-bit targets.
	* testsuite/experimental/optional/cons/move.cc: Likewise.
	* testsuite/experimental/optional/cons/value.cc: Likewise.
	* testsuite/experimental/optional/constexpr/cons/value.cc: Likewise.

Co-Authored-By: Paolo Carlini <paolo.carlini@oracle.com>

From-SVN: r204402
2013-11-05 15:24:08 +00:00
Jonathan Wakely
654a6bb421 Fix date of previous ChangeLog entry.
From-SVN: r204300
2013-11-01 20:10:51 +00:00