Commit Graph

4987 Commits

Author SHA1 Message Date
Jonathan Wakely 060269c481 re PR libstdc++/61390 (error in nested template parameter in ext/pb_ds header file)
PR libstdc++/61390
	* include/ext/pb_ds/detail/bin_search_tree_/traits.hpp
	(bin_search_tree_traits): Do not redeclare template-parameters.
	* testsuite/util/testsuite_iterators.h (test_container): Likewise.

From-SVN: r211421
2014-06-10 19:09:18 +01:00
Jonathan Wakely 45b4a79657 beta_function.tcc: Fix spelling of include guard in comment.
* include/tr1/beta_function.tcc: Fix spelling of include guard in
	comment.

From-SVN: r211373
2014-06-09 12:52:20 +01:00
Ed Smith-Rowland 25608e3a5f DR 2344 - std::quoted doesn't respect padding
2014-06-06  Ed Smith-Rowland  <3dw4rd@verizon.net>

	DR 2344 - std::quoted doesn't respect padding
	* include/std/iomanip: Allow for padding in quoted inserters.
	* testsuite/27_io/manipulators/standard/char/dr2344.cc: New.
	* testsuite/27_io/manipulators/standard/wchar_t/dr2344.cc: New.

From-SVN: r211340
2014-06-07 03:40:30 +00:00
Jonathan Wakely 097f0bcf65 regex_compiler.h (__detail::_BracketMatcher): Reorder members to avoid wasted space when not using a cache.
* include/bits/regex_compiler.h (__detail::_BracketMatcher): Reorder
	members to avoid wasted space when not using a cache.
	(__detail::_BracketMatcher::_M_ready()): Sort and deduplicate set.
	* include/bits/regex_compiler.tcc
	(__detail::_BracketMatcher::_M_apply(_CharT, false_type)): Use binary
	search on set.
	* include/bits/regex_executor.h (__detail::_Executor::_Match_mode):
	New enumeration type to indicate match mode.
	(__detail::_Executor::_State_info): New type holding members only
	needed in BFS-mode. Replace unique_ptr<vector<bool>> with
	unique_ptr<bool[]>.
	(__detail::_Executor::_M_rep_once_more, __detail::_Executor::_M_dfs):
	Replace template parameter with run-time function parameter.
	(__detail::_Executor::_M_main): Likewise. Dispatch to ...
	(__detail::_Executor::_M_main_dispatch): New overloaded functions to
	implement DFS and BFS mode.
	* include/bits/regex_executor.tcc (__detail::_Executor::_M_main):
	Split implementation into ...
	(__detail::_Executor::_M_main_dispatch): New overloaded functions.
	(__detail::_Executor::_M_lookahead): Create nested executor on stack.
	(__detail::_Executor::_M_rep_once_more): Pass match mode as function
	argument instead of template argument.
	(__detail::_Executor::_M_dfs): Likewise.
	* include/bits/regex_scanner.tcc: Fix typos in comments.
	* testsuite/performance/28_regex/range.cc: New.

From-SVN: r211143
2014-06-02 20:36:14 +01:00
Jonathan Wakely 315eb4bb08 condition_variable (condition_variable_any::_Unlock): Do not swallow __forced_unwind.
* include/std/condition_variable (condition_variable_any::_Unlock): Do
	not swallow __forced_unwind.
	* include/std/future (__future_base::_Task_setter): Likewise.
	(__future_base::_Async_state_impl): Turn __forced_unwind into broken
	promise and rethrow.
	* include/std/mutex (try_lock): Likewise.
	* testsuite/30_threads/async/forced_unwind.cc: New.
	* testsuite/30_threads/packaged_task/forced_unwind.cc: New.

From-SVN: r211138
2014-06-02 16:45:09 +01:00
Rüdiger Sonderfeld d371802725 type_traits (__strictest_alignment): New helper struct.
2014-06-02  Rüdiger Sonderfeld  <ruediger@c-plusplus.de>
	    Jonathan Wakely  <jwakely@redhat.com>

	* libstdc++-v3/include/std/type_traits (__strictest_alignment): New
	helper struct.
	(aligned_union): New struct (C++11).
	(aligned_union_t): New type alias (C++14).
	* doc/xml/manual/status_cxx2011.xml: Update.
	* libstdc++-v3/testsuite/20_util/aligned_union/1.cc: New file.
	* testsuite/20_util/declval/requirements/1_neg.cc: Adjust dg-error
	line number.

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

From-SVN: r211137
2014-06-02 14:55:14 +01:00
Jonathan Wakely 314efb66cf uses_allocator.h (__uses_allocator_helper): Simplify.
* include/bits/uses_allocator.h (__uses_allocator_helper): Simplify.
	(__uses_allocator_arg): Remove unused type.
	(__uses_alloc0): Turn into a trivial type.
	(__uses_alloc): Add missing template parameter in primary template.
	(__uses_alloc_impl): Rename to __uses_alloc_t.

From-SVN: r211121
2014-06-01 23:35:42 +01:00
Jonathan Wakely 16545743c6 re PR libstdc++/61374 (string_view::operator string() is buggy)
PR libstdc++/61374
	* include/experimental/string_view (operator basic_string): Correct
	order of arguments.
	(to_string): Replace with member function.
	Add inline specifiers. Remove unused header. Remove _S_empty_rep and
	allow _M_str to be null.
	* testsuite/experimental/string_view/cons/char/1.cc: Adjust to new
	default constructor semantics.
	* testsuite/experimental/string_view/cons/wchar_t/1.cc: Likewise.
	* testsuite/experimental/string_view/operations/copy/char/1.cc: Fix
	copyright dates. Remove unused header.
	* testsuite/experimental/string_view/operations/copy/wchar_t/1.cc:
	Likewise.
	* testsuite/experimental/string_view/operations/data/char/1.cc:
	Fix copyright dates. Adjust to new default constructor semantics.
	* testsuite/experimental/string_view/operations/data/wchar_t/1.cc:
	Likewise.
	* testsuite/experimental/string_view/operations/to_string/1.cc: New.

From-SVN: r211113
2014-06-01 18:23:41 +01:00
Jonathan Wakely 710d672b08 bool_set: Use UTF-8 for accented characters.
* include/tr2/bool_set: Use UTF-8 for accented characters.
	* scripts/run_doxygen: Handle Doxygen 1.8.x change.
	* doc/doxygen/user.cfg.in: Update to Doxygen 1.8.6 format. Set
	QUIET=YES, remove obsolete SYMBOL_CACHE_SIZE tag.

From-SVN: r211053
2014-05-29 15:04:43 +01:00
Jonathan Wakely ecb249ddf2 re PR libstdc++/61329 (#include <regex> and _GLIBCXX_DEBUG causes multiple symbol definition.)
PR libstdc++/61329
	* include/bits/regex_automaton.tcc (_State_base::_M_print): Add
	inline specifier.
	(_State_base::_M_dot): Likewise.

From-SVN: r210968
2014-05-27 12:14:17 +01:00
Paolo Carlini 5a2b79e24d map.h: Fix typo in comment; minor formatting fix.
2014-05-25  Paolo Carlini  <paolo.carlini@oracle.com>

	* include/profile/map.h: Fix typo in comment; minor formatting fix.
	* include/profile/multimap.h: Likewise.
	* include/profile/set.h: Likewise.
	* include/profile/multiset.h: Likewise.

From-SVN: r210912
2014-05-25 08:38:01 +00:00
François Dumont f3de79d43a array: Clean useless white chars.
2014-05-24  François Dumont  <fdumont@gcc.gnu.org>

	* include/profile/array: Clean useless white chars.
	* include/profile/base.h: Likewise.
	* include/profile/iterator_tracker.h: Likewise.
	* include/profile/bitset: Code cleanup and remove not instrumented code.
	* include/profile/deque: Likewise.
	* include/profile/forward_list: Likewise.
	* include/profile/list (std::__profile::_List_profile<>): New.
	(std::__profile::list<>): Inherit from latter and adapt.
	* include/profile/impl/profiler_map_to_unordered_map.h: Generalize
	advise to match any ordered to unordered container conversion.
	* include/profile/ordered_base.h (std::__profile::_Ordered_profile<>):
	New.
	* include/Makefile.am: Add latter.
	* include/Makefile.in: Regenerate.
	* include/profile/map.h (std::__profile::map<>): Inherit from latter,
	remove not instrumented code.
	* include/profile/multimap.h (std::__profile::multimap<>): Likewise.
	* include/profile/set.h (std::__profile::set<>): Likewise.
	* include/profile/multiset.h (std::__profile::multiset<>): Likewise.
	* include/profile/unordered_base.h: Add some line feed.
	* include/profile/unordered_map: Clean useless white chars and replace
	spaces with tabs.
	* include/profile/unordered_set: Likewise.
	* include/profile/vector (std::__profile::_Vector_profile_pre<>): New.
	(std::__profile::_Vector_profile_post<>): New.
	(std::__profile::vector<>): Inherit from latter and adapt.

From-SVN: r210900
2014-05-24 20:59:00 +00:00
François Dumont 95539f21f5 re PR libstdc++/61143 (Arithmetic exception on emplacing into unordered_map moved out)
2014-05-21  François Dumont  <fdumont@gcc.gnu.org>

	PR libstdc++/61143
	* include/bits/hashtable.h: Fix move semantic to leave hashtable in a
	usable state.
	* testsuite/23_containers/unordered_set/61143.cc: New.
	* testsuite/23_containers/unordered_set/modifiers/swap.cc: New.

From-SVN: r210726
2014-05-21 19:51:05 +00:00
Jonathan Wakely 21e2806a8f re PR libstdc++/61269 (<type_traits> includes <cstdint> inside std namespace)
PR libstdc++/61269
	* include/std/type_traits: Move include outside namespace std.
	* testsuite/20_util/declval/requirements/1_neg.cc: Adjust dg-error.
	* testsuite/20_util/make_signed/requirements/typedefs_neg.cc: Likewise.
	* testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc:
	Likewise.

From-SVN: r210715
2014-05-21 16:09:37 +01:00
Tim Shen 4dae67e090 re PR libstdc++/61227 ([C++11] Regex [\w] does not work)
2014-05-20  Tim Shen  <timshen91@gmail.com>

	PR libstdc++/61227
	* include/bits/regex_compiler.h
	(_BracketMatcher<>::_M_add_character_class): Add negative character
	class support.
	* include/bits/regex_compiler.tcc (_BracketMatcher<>::_M_apply):
	Likewise.
	* testsuite/28_regex/algorithms/regex_match/ecma/char/quoted_char.cc:
	Add more testcases.

From-SVN: r210630
2014-05-20 04:31:54 +00:00
Jonathan Wakely a0eaa08ceb re PR libstdc++/60966 (std::call_once sometime hangs)
PR libstdc++/60966
	* include/std/future (__future_base::_State_baseV2::_M_set_result):
	Pass lock into _M_do_set and hold it until the function returns.
	Signal condition variable after call_once completes.
	(__future_base::_State_baseV2::_M_do_set): Use lock argument. Do not
	signal here.
	* testsuite/30_threads/promise/60966.cc: New.

From-SVN: r210556
2014-05-17 13:58:46 +01:00
Jonathan Wakely cd1464dbc6 parse_numbers.h (__parse_int::_Number_help): Check for overflow.
* include/bits/parse_numbers.h (__parse_int::_Number_help): Check for
	overflow.
	* include/std/chrono (chrono_literals::__select_type::_Select_type):
	Remove.
	(chrono_literals::_Checked_integral_constant): Define.
	Simplify UDL operator templates and check for overflow.
	* testsuite/20_util/duration/literals/range.cc: New.

From-SVN: r210513
2014-05-16 12:08:49 +01:00
Ed Smith-Rowland a2f4bd2ae1 re PR libstdc++/61166 (overflow when parse number in std::duration operator"")
2014-05-15  Ed Smith-Rowland  <3dw4rd@verizon.net>
	    Jonathan Wakely  <jwakely@redhat.com>

	PR libstdc++/61166
	* include/bits/parse_numbers.h: Use integral_constant to remove
	duplication and simplify.
	* testsuite/20_util/duration/literals/61166.cc: New.

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

From-SVN: r210511
2014-05-16 10:30:57 +01:00
Jonathan Wakely c0eef1c8f2 re PR libstdc++/60326 (Incorrect type from std::make_unsigned<wchar_t>)
PR libstdc++/60326
	* include/std/type_traits (__make_unsigned, __make_signed): Define
	specializations for wchar_t, char16_t and char32_t.
	* testsuite/20_util/make_signed/requirements/typedefs-4.cc: New.
	* testsuite/20_util/make_unsigned/requirements/typedefs-1.cc: Correct
	test for make_unsigned<volatile wchar_t>.
	* testsuite/20_util/make_unsigned/requirements/typedefs-2.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: r210473
2014-05-15 13:31:05 +01:00
Jonathan Wakely 3a004764ec tuple (tuple_size<cv _Tp>): Implement LWG 2313.
* include/std/tuple (tuple_size<cv _Tp>): Implement LWG 2313.
	* include/std/array (tuple_size, tuple_element): Add Doxygen comments.
	* include/std/utility (tuple_size, tuple_element): Likewise.
	* testsuite/23_containers/array/tuple_interface/tuple_element_neg.cc:
	Adjust dg-error line number.

From-SVN: r210470
2014-05-15 11:35:29 +01:00
Jonathan Wakely af222e7486 tuple (__add_c_ref, [...]): Remove.
* include/std/tuple (__add_c_ref, __add_ref, __add_r_ref): Remove.
	(__tuple_element_t): Define.
	(tuple_element): Use __tuple_element_t.
	(__cv_tuple_size): Define.
	(tuple_size<cv _Tp>): Use __cv_tuple_size.
	(get, __get_helper, __get_helper2): Remove uses of __add_ref etc.
	(get<_Tp>(tuple<_Types...>&&)): Use forward instead of move.
	(__tuple_compare): Remove size check, re-order parameters.
	(operator==, operator<): Use static_assert to check requirements.
	* include/std/functional (__volget): use __tuple_element_t.
	* testsuite/20_util/tuple/element_access/get_by_type.cc: Test rvalues.
	* testsuite/20_util/uses_allocator/cons_neg.cc: Adjust dg-error.

From-SVN: r210447
2014-05-14 23:16:35 +01:00
Jonathan Wakely b82f988e8d re PR libstdc++/60497 (unique_ptr<T> tries to complete its type T even though it's not required to be a complete type)
PR libstdc++/60497
	* include/debug/array (get): Qualify call to other get overload.
	* include/profile/array (get): Likewise.
	* include/std/array (get): Likewise.
	* include/std/functional (_Mu, _Bind, _Bind_result): Qualify std::get.
	* include/std/mutex (unique_lock, call_once): Use __addressof.
	(__unlock_impl): Remove unused template.
	(__try_to_lock): Declare inline.
	(__try_lock_impl::__do_try_lock): Qualify function calls.
	(lock): Avoid narrowing conversion.
	* testsuite/20_util/bind/60497.cc: New.
	* testsuite/23_containers/array/element_access/60497.cc: New.
	* testsuite/30_threads/call_once/60497.cc: New.
	* testsuite/30_threads/unique_lock/cons/60497.cc: New.

From-SVN: r210388
2014-05-13 18:22:08 +01:00
Jonathan Wakely 75e75a087d re PR libstdc++/60497 (unique_ptr<T> tries to complete its type T even though it's not required to be a complete type)
PR libstdc++/60497
	* include/std/tuple (get, __tuple_compare): Qualify more calls to
	prevent ADL. Cast comparison results to bool.
	* testsuite/20_util/tuple/60497.cc: Test accessing rvalues.
	* testsuite/20_util/tuple/comparison_operators/overloaded.cc: New.

From-SVN: r210366
2014-05-13 12:18:01 +01:00
Jonathan Wakely 07e4f10aa6 iostream: Fix URL in comment.
* include/std/iostream: Fix URL in comment.
	* src/c++98/ios_init.cc: Fix path in comment.

From-SVN: r210232
2014-05-08 20:01:51 +01:00
Jonathan Wakely 2735097a55 re PR libstdc++/13860 (Poor error messages on invalid template parameters for basic_filebuf)
PR libstdc++/13860
	* include/std/fstream (basic_filebuf): Enforce requirements on traits.

From-SVN: r210231
2014-05-08 19:30:14 +01:00
Jonathan Wakely f0fd118f53 re PR libstdc++/57394 ([C++11] basic_streambuf incorrect copy constructor / copy assignment access specifier)
PR libstdc++/57394
	* include/bits/ios_base.h (ios_base(const ios_base&)): Define as
	deleted for C++11.
	(operator=(const ios_base&)): Likewise.
	* include/std/streambuf: Remove trailing whitespace.
	(basic_streambuf(const basic_streambuf&)): Fix initializer for
	_M_out_end. Define as defaulted for C++11.
	(operator=(const basic_streambuf&)): Define as defaulted for C++11.
	(swap(basic_streambuf&)): Define for C++11.
	* testsuite/27_io/basic_streambuf/cons/57394.cc: New.

From-SVN: r210228
2014-05-08 18:17:06 +01:00
Jonathan Wakely bbf264c9b2 re PR libstdc++/61086 (ubsan detects undefined behaviour in the standard library)
PR libstdc++/61086
	* include/bits/stl_iterator.h (__normal_iterator::_M_const_cast):
	Remove.
	* include/bits/stl_vector.h (vector::insert, vector::erase): Use
	arithmetic to obtain a mutable iterator from const_iterator.
	* include/bits/vector.tcc (vector::insert): Likewise.
	* include/debug/vector (vector::erase): Likewise.
	* 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: r210162
2014-05-07 15:43:22 +01:00
Jonathan Wakely 2588652e17 re PR libstdc++/61023 (set/map move assignment doesn't move (or copy) the comparator)
PR libstdc++/61023
	* include/bits/stl_tree.h (_Rb_tree::_M_move_assign): Copy the
	comparison function.
	* testsuite/23_containers/set/cons/61023.cc: New.

From-SVN: r210159
2014-05-07 15:12:37 +01:00
Paolo Carlini f03d1bb9cb Makefile.in: Regenerate.
2014-05-06  Paolo Carlini  <paolo.carlini@oracle.com>

	* include/Makefile.in: Regenerate.

From-SVN: r210133
2014-05-07 01:11:19 +00:00
François Dumont 15ee1a7745 macros.h [...]: Add parameter to pass the 2 instances to check allocator equality.
2014-05-06  François Dumont  <fdumont@gcc.gnu.org>

	* include/debug/macros.h [__glibcxx_check_equal_allocs]: Add
	parameter to pass the 2 instances to check allocator equality.
	* include/debug/safe_container.h: New, define _Safe_container<>.
	* include/Makefile.am: Add previous.
	* include/debug/deque (std::__debug::deque<>): Inherit
	_Safe_container<>. Use default implementation for all special
	functions.
	* include/debug/forward_list (std::__debug::forward_list<>):
	Likewise.
	* include/debug/list (std::__debug::list<>): Likewise.
	* include/debug/map.h (std::__debug::map<>): Likewise.
	* include/debug/multimap.h (std::__debug::multimap<>): Likewise.
	* include/debug/set.h (std::__debug::set<>): Likewise.
	* include/debug/multiset.h (std::__debug::multiset<>): Likewise.
	* include/debug/string (std::__debug::basic_string<>): Likewise.
	* include/debug/unordered_map
	(std::__debug::unordered_map<>): Likewise.
	(std::__debug::unordered_multimap<>): Likewise.
	* include/debug/unordered_set
	(std::__debug::unordered_set<>): Likewise.
	(std::__debug::unordered_multiset<>): Likewise.
	* include/debug/vector (std::__debug::vector<>): Likewise.
	* include/debug/safe_base.h (_Safe_sequence_base()): Add
	noexcept.
	(_Safe_sequence_base(_Safe_sequence_base&&): Remove.
	(~_Safe_sequence_base()): Add noexcept.
	* include/debug/safe_sequence.h
	(std::__debug::_Safe_node_sequence<>): New.
	* include/debug/safe_unordered_base.h
	(_Safe_unordered_container_base()): Add noexcept.
	(~_Safe_unordered_container_base()): Likewise.
	(_M_swap(_Safe_unordered_container_base&)): Likewise.
	* include/debug/safe_unordered_container.h:
	(_Safe_unordered_container<>::_M_invalidate_locals()): New.
	(_Safe_unordered_container<>::_M_invalidate_all()): New.
	* src/c++11/debug.cc: Limit includes, adapt methods noexcept
	qualifications.
	* testsuite/util/debug/checks.h (check_construct1): Just implement
	an invalid constructor invocation  and no other operations
	potentially not supported by some types of container.
	(check_construct2): Likewise.
	(check_construct3): Likewise.
	* testsuite/23_containers/forward_list/allocator/move.cc: Add
	check on iterators to make sure they are correctly moved in debug
	mode.
	* testsuite/23_containers/forward_list/allocator/move_assign.cc:
	Likewise.
	* testsuite/23_containers/map/allocator/move.cc: Likewise.
	* testsuite/23_containers/map/allocator/move_assign.cc: Likewise.
	* testsuite/23_containers/multimap/allocator/move.cc: Likewise.
	* testsuite/23_containers/multimap/allocator/move_assign.cc:
	Likewise.
	* testsuite/23_containers/multiset/allocator/move.cc: Likewise.
	* testsuite/23_containers/multiset/allocator/move_assign.cc:
	Likewise.
	* testsuite/23_containers/set/allocator/move.cc: Likewise.
	* testsuite/23_containers/set/allocator/move_assign.cc: Likewise.
	* testsuite/23_containers/unordered_map/allocator/move.cc:
	Likewise.
	* testsuite/23_containers/unordered_map/allocator/move_assign.cc:
	Likewise.
	* testsuite/23_containers/unordered_multimap/allocator/move.cc:
	Likewise.
	* testsuite/23_containers/unordered_multimap/allocator/move_assign.cc:
	Likewise.
	* testsuite/23_containers/unordered_multiset/allocator/move.cc:
	Likewise.
	* testsuite/23_containers/unordered_multiset/allocator/move_assign.cc:
	Likewise.
	* testsuite/23_containers/unordered_set/allocator/move.cc:
	Likewise.
	* testsuite/23_containers/unordered_set/allocator/move_assign.cc:
	Likewise.
	* testsuite/23_containers/forward_list/debug/construct1_neg.cc:
	New.
	* testsuite/23_containers/forward_list/debug/construct2_neg.cc:
	New.
	* testsuite/23_containers/forward_list/debug/construct3_neg.cc:
	New.
	* testsuite/23_containers/forward_list/debug/construct4_neg.cc:
	New.
	* testsuite/23_containers/forward_list/debug/move_assign_neg.cc:
	New.
	* testsuite/23_containers/forward_list/debug/move_neg.cc: New.
	* testsuite/23_containers/map/debug/construct5_neg.cc: New.
	* testsuite/23_containers/map/debug/move_assign_neg.cc: New.
	* testsuite/23_containers/map/debug/move_neg.cc: New.
	* testsuite/23_containers/multimap/debug/construct5_neg.cc: New.
	* testsuite/23_containers/multimap/debug/move_assign_neg.cc: New.
	* testsuite/23_containers/multimap/debug/move_neg.cc: New.
	* testsuite/23_containers/multiset/debug/construct5_neg.cc: New.
	* testsuite/23_containers/multiset/debug/move_assign_neg.cc: New.
	* testsuite/23_containers/multiset/debug/move_neg.cc: New.
	* testsuite/23_containers/set/debug/construct5_neg.cc: New.
	* testsuite/23_containers/set/debug/move_assign_neg.cc: New.
	* testsuite/23_containers/set/debug/move_neg.cc: New.
	* testsuite/23_containers/unordered_map/debug/construct5_neg.cc:
	New.
	* testsuite/23_containers/unordered_map/debug/move_assign_neg.cc:
	New.
	* testsuite/23_containers/unordered_map/debug/move_neg.cc: New.
	* testsuite/23_containers/unordered_multimap/debug/construct5_neg.cc:
	New.
	* testsuite/23_containers/unordered_multimap/debug/move_assign_neg.cc:
	New.
	* testsuite/23_containers/unordered_multimap/debug/move_neg.cc:
	New.
	* testsuite/23_containers/unordered_multiset/debug/construct5_neg.cc:
	New.
	* testsuite/23_containers/unordered_multiset/debug/move_assign_neg.cc:
	New.
	* testsuite/23_containers/unordered_multiset/debug/move_neg.cc:
	New.
	* testsuite/23_containers/unordered_set/debug/construct5_neg.cc:
	New.
	* testsuite/23_containers/unordered_set/debug/move_assign_neg.cc:
	New.
	* testsuite/23_containers/unordered_set/debug/move_neg.cc: New.
	* testsuite/23_containers/vector/debug/move_neg.cc: New.

From-SVN: r210123
2014-05-06 19:59:44 +00:00
Jonathan Wakely 62da5a07b2 re PR libstdc++/61036 (shared_ptr<void>(new T) rejected)
PR libstdc++/61036
	* include/bits/shared_ptr_base.h (__shared_ptr::__shared_ptr(_Tp1*)):
	Check the correct type in the static assertion.
	* testsuite/20_util/shared_ptr/cons/61036.cc: New.

From-SVN: r210015
2014-05-02 19:29:48 +01:00
Tim Shen a670a9bb54 regex_automaton.h (_NFA<>::_M_insert_repeat): Add _S_opcode_repeat support to distingush a loop from _S_opcode_alternative.
2014-04-27  Tim Shen  <timshen91@gmail.com>

	* include/bits/regex_automaton.h (_NFA<>::_M_insert_repeat):
	Add _S_opcode_repeat support to distingush a loop from
	_S_opcode_alternative.
	* include/bits/regex_automaton.tcc (_State_base::_M_print,
	_State_base::_M_dot, _NFA<>::_M_eliminate_dummy,
	_StateSeq<>::_M_clone): Likewise.
	* include/bits/regex_compiler.tcc (_Compiler<>::_M_quantifier):
	Likewise.
	* include/bits/regex_executor.tcc (_Executor<>::_M_dfs): Likewise.
	* include/bits/regex_scanner.tcc (_Scanner<>::_M_eat_escape_ecma):
	Uglify local variable __i.
	* include/bits/regex_compiler.h (_BracketMatcher<>::_M_make_cache):
	Use size_t instead of int to compare with vector::size().

2014-04-27  Tim Shen  <timshen91@gmail.com>

	* include/bits/regex_executor.h: Add _M_rep_count to track how
	many times this repeat node are visited.
	* include/bits/regex_executor.tcc (_Executor<>::_M_rep_once_more,
	_Executor<>::_M_dfs): Use _M_rep_count to prevent entering
	infinite loop.

2014-04-27  Tim Shen  <timshen91@gmail.com>

	* include/bits/regex.tcc (__regex_algo_impl<>): Remove
	_GLIBCXX_REGEX_DFS_QUANTIFIERS_LIMIT and use
	_GLIBCXX_REGEX_USE_THOMPSON_NFA instead.
	* include/bits/regex_automaton.h: Remove quantifier counting variable.
	* include/bits/regex_automaton.tcc (_State_base::_M_dot):
	Adjust debug NFA dump.

From-SVN: r209844
2014-04-27 23:48:47 +00:00
Lars Gullik Bjønnes e2ce9436fb re PR libstdc++/60710 (experimental::optional<T> is using T::operator!=)
2014-04-25  Lars Gullik Bjønnes  <larsbj@gullik.org>

	PR libstdc++/60710
	* include/experimental/optional (operator!=): Implement in terms of
	operator==.
	* testsuite/experimental/optional/relops/1.cc: Remove operator!=.
	* testsuite/experimental/optional/relops/2.cc: Likewise.
	* testsuite/experimental/optional/relops/3.cc: Likewise.
	* testsuite/experimental/optional/relops/4.cc: Likewise.
	* testsuite/experimental/optional/relops/5.cc: Likewise.
	* testsuite/experimental/optional/relops/6.cc: Likewise.

From-SVN: r209810
2014-04-25 20:34:42 +01:00
Jonathan Wakely 4ec21835cb re PR libstdc++/60958 (Initialization of arrays in tr1/regex ill-formed or with undefined behaviour)
PR libstdc++/60958
	* include/tr1/regex (regex_traits::isctype): Comment out broken code.
	* testsuite/util/testsuite_regex.h (regex_match_debug): Improve
	comment.

From-SVN: r209807
2014-04-25 17:10:25 +01:00
Tim Shen 836c42f6ad regex_automaton.tcc (_StateSeq<>::_M_clone()): Do _M_alt before _M_next.
2014-04-24  Tim Shen  <timshen91@gmail.com>

	* include/bits/regex_automaton.tcc (_StateSeq<>::_M_clone()):
	Do _M_alt before _M_next.
	* testsuite/28_regex/basic_regex/multiple_quantifiers.cc: Add testcases.

From-SVN: r209756
2014-04-24 18:29:21 +00:00
Jonathan Wakely 6e2d247b1e * include/std/functional (__is_location_invariant): Use __or_ helper.
From-SVN: r209445
2014-04-16 18:46:13 +01:00
Jonathan Wakely 33fbb3584a shared_ptr.h (shared_ptr::shared_ptr(nullptr_t)): Remove name of unused parameter.
* include/bits/shared_ptr.h (shared_ptr::shared_ptr(nullptr_t)):
	Remove name of unused parameter.

From-SVN: r209434
2014-04-15 21:15:38 +01:00
Jonathan Wakely b9de84c92d * include/experimental/string_view: Fix inconsistent exception specs.
From-SVN: r209433
2014-04-15 20:05:57 +01:00
Jonathan Wakely 227df36e33 * include/std/atomic: Uglify parameter names.
From-SVN: r209429
2014-04-15 19:28:57 +01:00
Jonathan Wakely ed39835fdc shared_ptr.h (shared_ptr::shared_ptr(nullptr_t)): Use delegating constructor.
* include/bits/shared_ptr.h (shared_ptr::shared_ptr(nullptr_t)): Use
	delegating constructor.
	* include/bits/shared_ptr_base.h
	(__shared_ptr::__shared_ptr(nullptr_t)): Likewise

From-SVN: r209428
2014-04-15 19:28:50 +01:00
Jonathan Wakely 260d16c8ca atomic_base.h (__atomic_base<_PTp*>::_M_type_size): Add const to constexpr member functions.
* include/bits/atomic_base.h (__atomic_base<_PTp*>::_M_type_size): Add
	const to constexpr member functions.

From-SVN: r209427
2014-04-15 19:28:41 +01:00
Jonathan Wakely 4803acceb2 re PR libstdc++/60594 (std::function of a type with a declared (but not defined) return type fails to compile)
PR libstdc++/60594
	* include/std/functional (function::_Callable): Exclude own type
	from the callable checks.
	* testsuite/20_util/function/60594.cc: New.

From-SVN: r209422
2014-04-15 16:25:52 +01:00
Jonathan Wakely 9ffc6d0bc2 re PR libstdc++/60695 (std::atomic<X> doesn't work when X is of zero size)
PR libstdc++/60695
	* include/std/atomic (atomic<_Tp>): Add static assertion.
	* testsuite/29_atomics/atomic/60695.cc: New.

From-SVN: r209418
2014-04-15 14:48:07 +01:00
Jonathan Wakely 4b3f982994 re PR libstdc++/60734 (Undefined behavior in g++-v4/bits/stl_tree.h)
PR libstdc++/60734
	* include/bits/stl_tree.h (_Rb_tree::_M_end): Fix invalid cast.

From-SVN: r209414
2014-04-15 11:52:06 +01:00
Jonathan Wakely 025eac9b9e N3887 Consistent Metafunction Aliases
* include/std/tuple (tuple_element_t): Define.
	* testsuite/20_util/tuple/tuple_element.cc: Change to compile-only
	test.
	* testsuite/20_util/tuple/tuple_element_t.cc: New.

From-SVN: r209395
2014-04-15 00:17:52 +01:00
Jonathan Wakely 39e6a690ec re PR libstdc++/60497 (unique_ptr<T> tries to complete its type T even though it's not required to be a complete type)
PR libstdc++/60497
	* include/std/tuple (get): Qualify calls to prevent ADL.
	* testsuite/20_util/tuple/60497.cc: New.

From-SVN: r209381
2014-04-14 16:32:58 +01:00
Jonathan Wakely e364673d87 allocator.h (operator==, operator!=): Add exception specifications.
* include/bits/allocator.h (operator==, operator!=): Add exception
	specifications.

From-SVN: r209379
2014-04-14 16:13:02 +01:00
Jonathan Wakely 5b99e0a022 Limit operations on vector::pointer to NullablePointer requirements.
* include/bits/stl_vector.h (_Vector_base::_Vector_impl,
	_Vector_base::_M_allocate): NullablePointer requirements do not
	include initialization from literal zero, use value-initialization.
	* include/bits/vector.tcc (vector::_M_insert_aux,
	vector::_M_explace_back_aux): Likewise for assignment.

From-SVN: r209377
2014-04-14 15:51:35 +01:00
Marc Glisse 4de3afd972 re PR libstdc++/59434 ([lwg/2106] move_iterator is broken for input iterators with an rvalue as reference type)
2014-04-11  Marc Glisse  <marc.glisse@inria.fr>

	PR libstdc++/59434
	* include/bits/stl_iterator.h (move_iterator::reference,
	move_iterator::operator*): Implement LWG 2106.
	* testsuite/24_iterators/move_iterator/dr2106.cc: New file.

From-SVN: r209323
2014-04-11 19:23:49 +00:00
Marc Glisse 742f66e736 complex (__complex_exp, pow): Specify the template parameter in calls to std::polar, for expression templates.
2014-04-11  Marc Glisse  <marc.glisse@inria.fr>

	* include/std/complex (__complex_exp, pow): Specify the template
	parameter in calls to std::polar, for expression templates.

From-SVN: r209321
2014-04-11 18:57:59 +00:00