aboutsummaryrefslogtreecommitdiff
path: root/libstdc++-v3
AgeCommit message (Collapse)AuthorFilesLines
2014-09-09Make std::deque meet C++11 allocator requirements.Jonathan Wakely19-95/+938
* include/bits/deque.tcc (deque::operator=(const deque&)): Handle allocator propagation. (deque::emplace_front, deque::emplace_back): Use allocator traits. (deque::_M_push_back_aux, deque::_M_push_front_aux): Likewise. (deque::_M_pop_back_aux, deque::_M_pop_front_aux): Likewise. * include/bits/stl_deque.h (__deque_buf_size): Add constexpr. (_Deque_iterator): Handle allocators with custom pointers. (_Deque_base): Likewise. Use allocator traits. (deque): Likewise. Add allocator-extended constructors. (deque::_M_move_assign1, deque::_M_move_assign2): Implement move assignment via tag dispatching. (deque::_M_replace_map): Replace existing data. * include/debug/deque (deque): Add allocator-extended constructors. * include/profile/deque (deque): Likewise. * testsuite/23_containers/deque/allocator/copy.cc: New. * testsuite/23_containers/deque/allocator/copy_assign.cc: New. * testsuite/23_containers/deque/allocator/ext_ptr.cc: New. * testsuite/23_containers/deque/allocator/minimal.cc: New. * testsuite/23_containers/deque/allocator/move.cc: New. * testsuite/23_containers/deque/allocator/move_assign-2.cc: New. * testsuite/23_containers/deque/allocator/move_assign.cc: New. * testsuite/23_containers/deque/allocator/noexcept.cc: New. * testsuite/23_containers/deque/allocator/swap.cc: New. * testsuite/23_containers/deque/requirements/dr438/assign_neg.cc: Adjust dg-error line number. * testsuite/23_containers/deque/requirements/dr438/ constructor_1_neg.cc: Likewise. * testsuite/23_containers/deque/requirements/dr438/ constructor_2_neg.cc: Likewise. * testsuite/23_containers/deque/requirements/dr438/insert_neg.cc: Likewise. * testsuite/23_containers/vector/52591.cc: Test both the propagating and always-equal cases. From-SVN: r215090
2014-09-06hashtable_policy.h (_Prime_rehash_policy): Constructor noexcept qualified.François Dumont11-42/+128
2014-09-06 François Dumont <fdumont@gcc.gnu.org> * include/bits/hashtable_policy.h (_Prime_rehash_policy): Constructor noexcept qualified. (_Hash_code_base<>): All specialization default constructible if possible. (_Hashtable_base<>): Likewise. * include/bits/hashtable.h (_Hashtable<>()): Implementation defaulted. * include/bits/unordered_map.h (unordered_map<>::unordered_map()): New, implementation defaulted. (unordered_multimap<>::unordered_multimap()): Likewise. * include/bits/unordered_set.h (unordered_set<>::unordered_set()): Likewise. (unordered_multiset<>::unordered_multiset()): Likewise. * include/debug/unordered_map: Likewise. * include/debug/unordered_set: Likewise. * testsuite/23_containers/unordered_map/allocator/noexcept.cc (test04()): New. * testsuite/23_containers/unordered_multimap/allocator/noexcept.cc (test04()): New. * testsuite/23_containers/unordered_set/allocator/noexcept.cc (test04()): New. * testsuite/23_containers/unordered_multiset/allocator/noexcept.cc (test04()): New. From-SVN: r214986
2014-08-30baseline_symbols.txt: Update.John David Anglin2-0/+48
* config/abi/post/hppa-linux-gnu/baseline_symbols.txt: Update. From-SVN: r214753
2014-08-29complex (complex): Define copy constructor and assignment operator as defaulted.Jonathan Wakely2-17/+27
* include/std/complex (complex): Define copy constructor and assignment operator as defaulted. Improve Doxygen comments. From-SVN: r214736
2014-08-28*: Fix incorrect standard references in comments.Jonathan Wakely43-71/+75
* testsuite/ext/random/*: Fix incorrect standard references in comments. From-SVN: r214681
2014-08-27re PR libstdc++/62159 (Missing headers for freestanding implementation)Jonathan Wakely3-18/+33
PR libstdc++/62159 * include/Makefile.am (install-freestanding-headers): Add missing C++11 headers. * include/Makefile.in: Regenerate. From-SVN: r214580
2014-08-26Whitespace fixes in libstdc++-v3/ChangeLogJonathan Wakely1-2/+2
From-SVN: r214501
2014-08-2162154.cc: Disable when the target doesn't provide atomic builtins.Tony Wang2-0/+6
2014-08-21 Tony Wang <tony.wang@arm.com> libstdc++-v3/ * testsuite/18_support/nested_exception/62154.cc: Disable when the target doesn't provide atomic builtins. From-SVN: r214261
2014-08-19os_defines.h (_GLIBCXX_THREAD_ATEXIT_WIN32): Define.Yaakov Selkowitz4-0/+44
2014-08-19 Yaakov Selkowitz <yselkowi@redhat.com> Kai Tietz <ktietz@redhat.com> * config/os/mingw32-w64/os_defines.h (_GLIBCXX_THREAD_ATEXIT_WIN32): Define. * config/os/newlib/os_defines.h (_GLIBCXX_THREAD_ATEXIT_WIN32): Ditto. * libsupc++/atexit_thread.cc [_GLIBCXX_THREAD_ATEXIT_WIN32]: #include <windows.h>. (struct elt): Add dll member. (run): Decrement dll refcount. (__cxxabiv1::__cxa_thread_atexit): Increment dll refcount. Co-Authored-By: Kai Tietz <ktietz@redhat.com> From-SVN: r214163
2014-08-15re PR libstdc++/62154 (std::throw_with_nested should not require a ↵Jonathan Wakely3-59/+133
polymorphic type) PR libstdc++/62154 * libsupc++/nested_exception.h (throw_with_nested, rethrow_if_nested): Rewrite to conform to C++11 requirements. * testsuite/18_support/nested_exception/62154.cc: New. From-SVN: r214025
2014-08-14requirements: Remove empty directory.Matthias Klose1-0/+5
2014-08-14 Matthias Klose <doko@ubuntu.com> * testsuite/ext/random/uniform_on_sphere_distribution/requirements: Remove empty directory. From-SVN: r213958
2014-08-14parser.c (cp_parser_init_declarator): Remove redundant check of ↵Paolo Carlini3-6/+9
decl_specifiers->type. /gcc/cp 2014-08-14 Paolo Carlini <paolo.carlini@oracle.com> * parser.c (cp_parser_init_declarator): Remove redundant check of decl_specifiers->type. /gcc/testsuite 2014-08-14 Paolo Carlini <paolo.carlini@oracle.com> * g++.dg/cpp0x/alias-decl-4.C: Adjust for parser change. * g++.dg/cpp0x/decltype2.C: Likewise. * g++.dg/cpp0x/decltype3.C: Likewise. * g++.dg/cpp0x/pr60249.C: Likewise. * g++.dg/cpp0x/variadic-ex10.C: Likewise. * g++.dg/cpp0x/variadic-ex14.C: Likewise. * g++.dg/cpp0x/variadic2.C: Likewise. * g++.dg/cpp0x/variadic74.C: Likewise. * g++.dg/parse/error10.C: Likewise. * g++.dg/parse/error15.C: Likewise. * g++.dg/parse/error2.C: Likewise. * g++.dg/template/crash106.C: Likewise. * g++.dg/template/crash89.C: Likewise. * g++.dg/template/nontype7.C: Likewise. * g++.dg/template/void3.C: Likewise. * g++.dg/template/void7.C: Likewise. /libstdc++-v3 2014-08-14 Paolo Carlini <paolo.carlini@oracle.com> * testsuite/26_numerics/random/linear_congruential_engine/ requirements/non_uint_neg.cc: Adjust for parser change. * testsuite/tr1/5_numerical_facilities/random/linear_congruential/ requirements/non_uint_neg.cc: Likewise. From-SVN: r213952
2014-08-13re PR libstdc++/61841 (broken std::thread on Hurd)Jonathan Wakely4-0/+29
PR libstdc++/61841 * include/std/thread (thread::_M_start_thread): Declare new overload. (thread::thread<_Callable, _Args...>): Call new overload with an explicit reference to pthread_create. * src/c++11/thread.cc (thread::_M_start_thread): Add new overload. * config/abi/pre/gnu.ver: Export new function. From-SVN: r213922
2014-08-13Fix the date ...Sylvestre Ledru1-1/+1
From-SVN: r213916
2014-08-13profiler_hash_func.h: Fix a comment typoSylvestre Ledru2-1/+5
2014-08-12 Sylvestre Ledru <sylvestre@debian.org> * include/profile/impl/profiler_hash_func.h: Fix a comment typo From-SVN: r213914
2014-08-132014-08-13 Paolo Carlini <paolo.carlini@oracle.com>Paolo Carlini2-1/+5
* Fix thinko in the last commit. From-SVN: r213908
2014-08-13re PR libstdc++/62118 (cases under libstdc++-v3/testsuite/ext/ failed on ↵Paolo Carlini2-2/+14
aarch64/arm) 2014-08-13 Paolo Carlini <paolo.carlini@oracle.com> PR libstdc++/62118 * include/ext/random.tcc (uniform_on_sphere_helper<2, _RealType>:: operator()): Use std::hypot only when _GLIBCXX_USE_C99_MATH_TR1. From-SVN: r213906
2014-08-12* include/bits/basic_string.h (getline): Declare inline.Jonathan Wakely2-1/+3
From-SVN: r213873
2014-08-12basic_string.h (getline): Qualify call to prevent ADL and add overloads for ↵Jonathan Wakely4-1/+102
rvalue streams. * include/bits/basic_string.h (getline): Qualify call to prevent ADL and add overloads for rvalue streams. * testsuite/21_strings/basic_string/inserters_extractors/char/12.cc: New. * testsuite/21_strings/basic_string/inserters_extractors/wchar_t/12.cc: New. From-SVN: r213869
2014-08-09random.tcc (uniform_on_sphere_helper): Define.Ulrich Drepper6-16/+161
* include/ext/random.tcc (uniform_on_sphere_helper): Define. (uniform_on_sphere_distribution::operator()): Use the new helper class for the implementation. * testsuite/ext/random/uniform_on_sphere_distribution/operators/ equal.cc: Remove bogus part of comment. * testsuite/ext/random/uniform_on_sphere_distribution/operators/ inequal.cc: Likewise. * testsuite/ext/random/uniform_on_sphere_distribution/operators/ serialize.cc: Add check to verify result of serialzation and deserialization. * testsuite/ext/random/uniform_on_sphere_distribution/operators/ generate.cc: New file. From-SVN: r213779
2014-08-092014-08-09 Paolo Carlini <paolo.carlini@oracle.com>Paolo Carlini1-1/+1
* Adjust date. From-SVN: r213777
2014-08-09invoke.texi ([Wnarrowing]): Update for non-constants in C++11.Paolo Carlini2-1/+8
2014-08-09 Paolo Carlini <paolo.carlini@oracle.com> * doc/invoke.texi ([Wnarrowing]): Update for non-constants in C++11. gcc/cp 2014-08-09 Paolo Carlini <paolo.carlini@oracle.com> * typeck2.c (check_narrowing): Add tsubst_flags_t parameter, change return type to bool; in C++11 for constants give errors, not pedwarns. * cp-tree.h (check_narrowing): Adjust declaration. * call.c (convert_like_real): Update calls. * semantics.c (finish_compound_literal): Likewise. gcc/testsuite 2014-08-09 Paolo Carlini <paolo.carlini@oracle.com> * g++.dg/cpp0x/Wnarrowing1.C: Adjust for errors. * g++.dg/cpp0x/enum29.C: Adjust. /libstdc++-v3 2014-08-09 Paolo Carlini <paolo.carlini@oracle.com> * include/ext/pod_char_traits.h (char_traits<__gnu_cxx:: character<_Value, _Int, _St> >::eof): Fix vs narrowing conversion. From-SVN: r213776
2014-08-09re PR libstdc++/61667 (setting max_load_factor of unordered_map cause ↵François Dumont3-4/+56
buckets shrink) 2014-08-09 François Dumont <fdumont@gcc.gnu.org> PR libstdc++/61667 * include/bits/hashtable.h (_Hashtable<>::__rehash_policy): Use _M_need_rehash to initialize the rehash policy and check if a rehash is needed. * testsuite/23_containers/unordered_map/modifiers/61667.cc: New. From-SVN: r213775
2014-08-07future (__location_invariant): Move specializations after preprocessor ↵Jonathan Wakely2-2/+5
condition. * include/std/future (__location_invariant): Move specializations after preprocessor condition. From-SVN: r213744
2014-08-07future (_State_baseV2::_M_set_result): Pass pointers to _M_do_set.Jonathan Wakely2-71/+66
* include/std/future (_State_baseV2::_M_set_result): Pass pointers to _M_do_set. (_State_baseV2::_M_do_set): Change parameters to pointers. (_State_baseV2::_Setter): Change _M_arg from reference to pointer. (_State_baseV2::__setter): Initialize _Setter with pointers. (_State_baseV2::__setter(promise<void>*)): Remove overload. (promise::set_value, promise::set_exception): Pass setter directly to _M_set_result. (_State_baseV2::_Task_setter): Add template parameter for callable type and replace std::function member with pointer to that type. Change _M_result member from reference to pointer. (_State_baseV2::_S_task_setter): Change parameter to lvalue reference and initialize _Task_setter with pointers. (__location_invariant): Specialize for _Setter and _Task_setter. From-SVN: r213737
2014-08-07stl_list.h (_List_base::_List_base(_List_base&&)): Optimize.Jonathan Wakely6-6/+28
* include/bits/stl_list.h (_List_base::_List_base(_List_base&&)): Optimize. * testsuite/23_containers/list/requirements/dr438/assign_neg.cc: Adjust dg-error line number. * testsuite/23_containers/list/requirements/dr438/constructor_1_neg.cc: Likewise. * testsuite/23_containers/list/requirements/dr438/constructor_2_neg.cc: Likewise. * testsuite/23_containers/list/requirements/dr438/insert_neg.cc: Likewise. From-SVN: r213716
2014-08-02re PR c++/15339 ([DR217] Adding default arguments to function templates in ↵Paolo Carlini2-1/+6
redeclarations should be forbidden) 2014-08-02 Paolo Carlini <paolo.carlini@oracle.com> PR c++/15339 * testsuite/26_numerics/headers/complex/synopsis.cc: Fix. From-SVN: r213520
2014-08-01atexit_thread.cc (HAVE___CXA_THREAD_ATEXIT_IMPL): Add _GLIBCXX_ prefix to macro.Zifei Tong2-3/+8
2014-08-01 Zifei Tong <zifeitong@gmail.com> * libsupc++/atexit_thread.cc (HAVE___CXA_THREAD_ATEXIT_IMPL): Add _GLIBCXX_ prefix to macro. From-SVN: r213504
2014-07-29* python/libstdcxx/v6/printers.pyJonathan Wakely2-2/+7
(SingleObjContainerPrinter._contained): Use compatibility mixin. From-SVN: r213227
2014-07-292014-07-29 François Dumont <fdumont@gcc.gnu.org>François Dumont12-164/+229
* testsuite/util/testsuite_allocator.h (tracker_allocator_counter::allocate): Remove new invocation, only collect information. (tracker_allocator_counter::deallocate): Remove delete invocation, only collect information. (check_inconsistent_alloc_value_type): New. (tracker_allocator): Transform as a facade for any allocator type. (uneq_allocator): Likewise. (propagating_allocator): Likewise. * testsuite/23_containers/forward_list/debug/move_assign_neg.cc: Use an explicitly non propagating allocator. * testsuite/23_containers/map/debug/move_assign_neg.cc: Likewise. * testsuite/23_containers/multimap/debug/move_assign_neg.cc: likewise. * testsuite/23_containers/multiset/debug/move_assign_neg.cc: Likewise. * testsuite/23_containers/set/debug/move_assign_neg.cc: Likewise. * testsuite/23_containers/unordered_map/debug/move_assign_neg.cc: Likewise. * testsuite/23_containers/unordered_multimap/debug/move_assign_neg.cc: Likewise. * testsuite/23_containers/unordered_multiset/debug/move_assign_neg.cc: Likewise. * testsuite/23_containers/unordered_set/debug/move_assign_neg.cc: Likewise. * testsuite/23_containers/vector/debug/move_assign_neg.cc: Likewise. From-SVN: r213224
2014-07-29re PR libstdc++/61947 (Ambiguous calls when constructing std::tuple)Jonathan Wakely4-14/+52
PR libstdc++/61947 * include/std/tuple (_Head_base): Use allocator_arg_t parameters to disambiguate unary constructors. (_Tuple_impl): Pass allocator_arg_t arguments. * testsuite/20_util/tuple/61947.cc: New. * testsuite/20_util/uses_allocator/cons_neg.cc: Adjust dg-error line. From-SVN: r213221
2014-07-29re PR libstdc++/61946 (rope construction, passing allocator referenct ↵Jonathan Wakely3-3/+43
without const) PR libstdc++/61946 * include/ext/rope (rope::rope(char_producer<_CharT>*, size_t, bool, const allocator_type&)): Pass non-const allocator to _S_new_RopeFunction. * testsuite/ext/rope/61946.cc: New. From-SVN: r213220
2014-07-29PR libstdc++/60037 - SIGFPE in std::generate_canonical<unsigned int...>Ed Smith-Rowland6-1/+55
2014-07-29 Ed Smith-Rowland <3dw4rd@verizon.net> PR libstdc++/60037 - SIGFPE in std::generate_canonical<unsigned int...> * include/bits/random.h (_Adaptor): static_assert for non floating-point result type. * include/bits/random.tcc (generate_canonical): Ditto. * include/ext/random.tcc (hypergeometric_distribution::operator()): Use double as a rng result type. * testsuite/26_numerics/random/pr60037-neg.cc: New. * testsuite/ext/random/hypergeometric_distribution/pr60037.cc: New. From-SVN: r213207
2014-07-25baseline_symbols.txt: Update.Uros Bizjak2-0/+15
* config/abi/post/alpha-linux-gnu/baseline_symbols.txt: Update. From-SVN: r213040
2014-07-25string_view: Make the literal operators constexpr like the ctors they call.Ed Smith-Rowland2-4/+9
2014-07-25 Ed Smith-Rowland <3dw4rd@verizon.net> * include/experimental/string_view: Make the literal operators constexpr like the ctors they call. From-SVN: r213037
2014-07-23Add a blank lineH.J. Lu1-0/+1
From-SVN: r212964
2014-07-23Update x32 baseline_symbols.txtH.J. Lu2-0/+26
* config/abi/post/x86_64-linux-gnu/x32/baseline_symbols.txt: Update. From-SVN: r212963
2014-07-23printers.py (StdExpAnyPrinter): Convert type to string instead of using ↵Jonathan Wakely2-1/+6
gdb.Type.name attribute. * python/libstdcxx/v6/printers.py (StdExpAnyPrinter): Convert type to string instead of using gdb.Type.name attribute. From-SVN: r212929
2014-07-19acinclude.m4 (GLIBCXX_CHECK_SDT_H): Replace AC_MSG_RESULT with AC_MSG_CHECKING.Jonathan Wakely3-3/+8
* acinclude.m4 (GLIBCXX_CHECK_SDT_H): Replace AC_MSG_RESULT with AC_MSG_CHECKING. From-SVN: r212848
2014-07-18re PR libstdc++/61835 (Invalid comment on pretty printers breaks gdb)Jonathan Wakely2-1/+11
PR libstdc++/61835 * python/libstdcxx/v6/printers.py (TemplateTypePrinter): Use raw string. (SingleObjContainerPrinter): Check if type printers are in use. From-SVN: r212822
2014-07-16random: Minor formatting and cosmetic tweaks.Paolo Carlini3-19/+31
2014-07-16 Paolo Carlini <paolo.carlini@oracle.com> * include/ext/random: Minor formatting and cosmetic tweaks. (uniform_on_sphere_distribution<>::operator== (const uniform_on_sphere_distribution&, const uniform_on_sphere_distribution&)): Compare the _M_nds. (uniform_on_sphere_distribution<>::reset): Reset _M_nd. (operator!=(const uniform_on_sphere_distribution&, const uniform_on_sphere_distribution&)): Adjust. * include/ext/random.tcc: Minor cosmetc tweaks. From-SVN: r212674
2014-07-15printers.py (SingleObjContainerPrinter): New base class for ↵Jonathan Wakely3-2/+204
experimental::any and experimental::optional printers. * python/libstdcxx/v6/printers.py (SingleObjContainerPrinter): New base class for experimental::any and experimental::optional printers. (StdExpAnyPrinter, StdExpOptionalPrinter, StdExpStringViewPrinter): New printers for Fundamentals TS types. * testsuite/libstdc++-prettyprinters/libfundts.cc: New. From-SVN: r212556
2014-07-15printers.py (TemplateTypePrinter): Add type printer for class templates.Jonathan Wakely3-0/+155
* python/libstdcxx/v6/printers.py (TemplateTypePrinter): Add type printer for class templates. (register_type_printers): Use TemplateTypePrinter for containers and other class templates with default template arguments. * testsuite/libstdc++-prettyprinters/whatis.cc: Test new recognizers. From-SVN: r212555
2014-07-15re PR libstdc++/61720 (std::regex_search matches incorrectly)Tim Shen3-0/+56
PR libstdc++/61720 * include/bits/regex_executor.tcc (_Executor<>::_M_main_dispatch): Clear match queue for next use. * testsuite/28_regex/algorithms/regex_search/61720.cc: New file. From-SVN: r212539
2014-07-14random.tcc: Unfortunately more fixes for operator>> and operator<< for...Ulrich Drepper2-2/+7
* include/ext/random.tcc: Unfortunately more fixes for operator>> and operator<< for uniform_on_sphere_distribution. From-SVN: r212517
2014-07-13random.tcc: Fix operator>> and operator<< for uniform_on_sphere_distribution.Ulrich Drepper2-2/+7
* include/ext/random.tcc: Fix operator>> and operator<< for uniform_on_sphere_distribution. From-SVN: r212496
2014-07-13random: Add uniform_on_sphere_distribution definition.Ulrich Drepper7-12/+457
2014-07-12 Ulrich Drepper <drepper@gmail.com> * include/ext/random: Add uniform_on_sphere_distribution definition. * include/ext/random.tcc: Add out-of-band member function definitions for uniform_on_sphere_distribution. * testsuite/ext/random/uniform_on_sphere_distribution/ cons/default.cc: New file. * testsuite/ext/random/uniform_on_sphere_distribution/ operators/equal.cc: New file. * testsuite/ext/random/uniform_on_sphere_distribution/ operators/inequal.cc: New file. * testsuite/ext/random/uniform_on_sphere_distribution/ operators/serialize.cc: New file. From-SVN: r212492
2014-07-12Add the logistic_distribution as an extension.Edward Smith-Rowland9-35/+633
2014-07-11 Edward Smith-Rowland <3dw4rd@verizon.net> Add the logistic_distribution as an extension. * include/ext/random: Add the logistic_distribution. * include/ext/random.tcc: Add the logistic_distribution. * testsuite/ext/random/logistic_distribution/cons/parms.cc: New. * testsuite/ext/random/logistic_distribution/cons/default.cc: New. * testsuite/ext/random/logistic_distribution/requirements/typedefs.cc: New. * testsuite/ext/random/logistic_distribution/operators/inequal.cc: New. * testsuite/ext/random/logistic_distribution/operators/equal.cc: New. * testsuite/ext/random/logistic_distribution/operators/serialize.cc: New. From-SVN: r212476
2014-07-11gdb-test.exp (gdb-test): Turn off GDB's auto-load, list loaded libs.Samuel Bronson2-2/+12
2014-07-11 Samuel Bronson <naesten@gmail.com> * testsuite/lib/gdb-test.exp (gdb-test): Turn off GDB's auto-load, list loaded libs. From-SVN: r212459
2014-07-11libstdc++.exp (libstdc++_init): Set $GCC_COLORS="" instead of insisting that ↵Samuel Bronson2-1/+8
GCC understand... 2014-07-11 Samuel Bronson <naesten@gmail.com> * testsuite/lib/libstdc++.exp (libstdc++_init): Set $GCC_COLORS="" instead of insisting that GCC understand -fdiagnostics-color=never From-SVN: r212458