Implement P1814R0, CTAD for alias templates.
[platform/upstream/gcc.git] / libstdc++-v3 / ChangeLog
index 3e4e898..23395b1 100644 (file)
@@ -1,3 +1,171 @@
+2019-11-26  François Dumont  <fdumont@gcc.gnu.org>
+
+       * include/debug/helper_functions.h (__valid_range_aux): Use C++98
+       std::input_iterator_tag default constructor invocation.
+
+       * include/debug/array (array<>::fill): Add C++20 constexpr.
+       (array<>::swap): Likewise.
+
+       * include/debug/safe_iterator.h
+       [__cpp_lib_concepts](_Safe_iterator<>::iterator_concept): Define for
+       C++20.
+
+2019-11-25  Jonathan Wakely  <jwakely@redhat.com>
+
+       * include/bits/iterator_concepts.h (ranges::iter_swap): Fix parameter
+       types of poison pill overload. Use remove_reference_t when checking
+       constraints.
+       * include/bits/stl_iterator.h (move_sentinel): Define for C++20.
+       (move_iterator): Adjust definitions of nested types for C++20. Add
+       hidden friends for move_sentinel operations, iter_move and iter_swap.
+       (common_iterator, counted_iterator): Define for C++20.
+       * testsuite/24_iterators/move_iterator/cust.cc: New test.
+       * testsuite/24_iterators/move_iterator/sentinel.cc: New test.
+       * testsuite/24_iterators/common_iterator/1.cc: New test.
+       * testsuite/24_iterators/counted_iterator/1.cc: New test.
+
+       PR libstdc++/91786
+       * include/bits/fs_path.h (filesystem_error): Move definition before
+       the use in u8path.
+
+2019-11-24  François Dumont  <fdumont@gcc.gnu.org>
+
+       * include/debug/functions.h: Remove <bits/move.h> include.
+       (__check_singular_aux, __check_singular): Move...
+       * include/debug/helper_functions.h:
+       (__check_singular_aux, __check_singular): ...here.
+       (__valid_range_aux): Adapt to use latter.
+       * testsuite/25_algorithms/copy/debug/2_neg.cc: New.
+
+2019-11-20  Janne Blomqvist  <jb@gcc.gnu.org>
+
+       * doc/html/api.html: Use https for gcc.gnu.org.
+       * doc/xml/api.xml: Likewise.
+
+2019-11-19  Jonathan Wakely  <jwakely@redhat.com>
+
+       * include/bits/regex.h (ranges::__detail::__enable_view_impl): Fix
+       declaration.
+       * include/bits/stl_multiset.h (ranges::__detail::__enable_view_impl):
+       Likewise.
+       * include/bits/stl_set.h (ranges::__detail::__enable_view_impl):
+       Likewise.
+       * include/bits/unordered_set.h (ranges::__detail::__enable_view_impl):
+       Likewise.
+       * include/debug/multiset.h (ranges::__detail::__enable_view_impl):
+       Likewise.
+       * include/debug/set.h (ranges::__detail::__enable_view_impl): Likewise.
+       * include/debug/unordered_set (ranges::__detail::__enable_view_impl):
+       Likewise.
+
+2019-11-18  Jonathan Wakely  <jwakely@redhat.com>
+
+       * include/std/thread: Reduce header dependencies.
+       (jthread::get_id()): Add missing return.
+       (jthread::get_stop_token()): Avoid unnecessary stop_source temporary.
+       (jthread::_S_create): Check is_invocable using decayed types. Add
+       static assertion.
+       * testsuite/30_threads/jthread/1.cc: Add dg-require-gthreads.
+       * testsuite/30_threads/jthread/2.cc: Likewise.
+       * testsuite/30_threads/jthread/3.cc: New test.
+       * testsuite/30_threads/jthread/jthread.cc: Add missing directives for
+       pthread and gthread support. Use VERIFY instead of assert.
+
+       * include/bits/alloc_traits.h (allocator_traits::construct)
+       (allocator_traits::destroy, allocator_traits::max_size): Add unused
+       attributes to parameters that are not used in C++20.
+       * include/std/bit (__ceil2): Add braces around assertion to avoid
+       -Wmissing-braces warning.
+
+2019-11-16  Edward Smith-Rowland  <3dw4rd@verizon.net>
+
+       Repair the <tuple> part of C++20 p1032 Misc constexpr bits.
+       * include/bits/uses_allocator.h (__uses_alloc0::_Sink::operaror=)
+       (__use_alloc(const _Alloc&)) : Constexpr.
+
+2019-11-17  Jonathan Wakely  <jwakely@redhat.com>
+
+       * include/std/string_view (basic_string_view(It, End)): Add range
+       constructor and deduction guide from P1391R4.
+       * testsuite/21_strings/basic_string_view/cons/char/range.cc: New test.
+
+       * include/bits/regex.h (match_results): Specialize __enable_view_impl.
+       * include/bits/stl_set.h (set): Likewise.
+       * include/bits/unordered_set.h (unordered_set, unordered_multiset):
+       Likewise.
+       * include/debug/multiset.h (__debug::multiset): Likewise.
+       * include/debug/set.h (__debug::set): Likewise.
+       * include/debug/unordered_set (__debug::unordered_set)
+       (__debug::unordered_multiset): Likewise.
+       * include/std/ranges (ranges::view, ranges::enable_view)
+       (ranges::view_interface, ranges::subrange, ranges::empty_view)
+       (ranges::single_view, ranges::views::single, ranges::iota_view)
+       (ranges::views::iota): Define for C++20.
+       * testsuite/std/ranges/empty_view.cc: New test.
+       * testsuite/std/ranges/iota_view.cc: New test.
+       * testsuite/std/ranges/single_view.cc: New test.
+       * testsuite/std/ranges/view.cc: New test.
+
+2019-11-16  Jonathan Wakely  <jwakely@redhat.com>
+
+       * include/std/ranges: Revert accidentally committed changes.
+
+       * include/std/thread (jthread::jthread()): Use nostopstate constant.
+       (jthread::jthread(Callable&&, Args&&...)): Use helper function to
+       create std::thread instead of indirection through a lambda. Use
+       remove_cvref_t instead of decay_t.
+       (jthread::joinable(), jthread::get_id(), jthread::native_handle())
+       (jthread::hardware_concurrency()): Add nodiscard attribute.
+       (swap(jthread&. jthread&)): Define hidden friend.
+       (jthread::_S_create): New helper function for constructor.
+
+2019-11-15  Edward Smith-Rowland  <3dw4rd@verizon.net>
+
+       Implement the <tuple> part of C++20 p1032 Misc constexpr bits.
+       * include/std/tuple (_Head_base, _Tuple_impl(allocator_arg_t,...)
+       (_M_assign, tuple(allocator_arg_t,...), _Inherited, operator=, _M_swap)
+       (swap, pair(piecewise_construct_t,): Constexpr.
+       * (__uses_alloc0::_Sink::operator=, __uses_alloc_t): Constexpr.
+       * testsuite/20_util/tuple/cons/constexpr_allocator_arg_t.cc: New test.
+       * testsuite/20_util/tuple/constexpr_swap.cc : New test.
+       * testsuite/20_util/uses_allocator/69293_neg.cc: Extra error for C++20.
+       * testsuite/20_util/uses_allocator/cons_neg.cc: : Extra error for C++20.
+
+2019-11-15  Jonathan Wakely  <jwakely@redhat.com>
+
+       * include/std/stop_token: Reduce header dependencies by including
+       internal headers.
+       (stop_token::swap(stop_token&), swap(stop_token&, stop_token&)):
+       Define.
+       (operator!=(const stop_token&, const stop_token&)): Fix return value.
+       (stop_token::_Stop_cb::_Stop_cb(Cb&&)): Use std::forward instead of
+       (stop_token::_Stop_state_t) [_GLIBCXX_HAS_GTHREADS]: Use lock_guard
+       instead of unique_lock.
+       [!_GLIBCXX_HAS_GTHREADS]: Do not use mutex.
+       (stop_token::stop_token(_Stop_state)): Change parameter to lvalue
+       reference.
+       (stop_source): Remove unnecessary using-declarations for names only
+       used once.
+       (swap(stop_source&, stop_source&)): Define.
+       (stop_callback(const stop_token&, _Cb&&))
+       (stop_callback(stop_token&&, _Cb&&)): Replace lambdas with a named
+       function. Use std::forward instead of std::move. Run callbacks if a
+       stop request has already been made.
+       (stop_source::_M_execute()): Remove.
+       (stop_source::_S_execute(_Stop_cb*)): Define.
+       * include/std/version (__cpp_lib_jthread): Define conditionally.
+       * testsuite/30_threads/stop_token/stop_callback.cc: New test.
+       * testsuite/30_threads/stop_token/stop_source.cc: New test.
+       * testsuite/30_threads/stop_token/stop_token.cc: Enable test for
+       immediate execution of callback.
+
+2019-11-15  Edward Smith-Rowland  <3dw4rd@verizon.net>
+
+       Implement the default_searcher part of C++20 p1032 Misc constexpr bits.
+       * include/std/functional
+       (default_searcher, default_searcher::operator()): Constexpr.
+       * testsuite/20_util/function_objects/constexpr_searcher.cc: New.
+
 2019-11-15  Jonathan Wakely  <jwakely@redhat.com>
 
        * include/bits/iterator_concepts.h (weakly_incrementable): Adjust.
        * doc/xml/manual/codecvt.xml: Switch pubs.opengroup.org to https.
        * doc/xml/manual/locale.xml (LC_ALL): Ditto.
        * doc/xml/manual/messages.xml: Ditto.
-       
+
 2019-10-26  John David Anglin  <danglin@gcc.gnu.org>
 
        * config/abi/post/hppa-linux-gnu/baseline_symbols.txt: Update.
        pubs.opengroup.org to https.
 
 2019-10-25  Gerald Pfeifer  <gerald@pfeifer.com>
-       
+
        * doc/xml/gnu/gpl-3.0.xml: Switch www.gnu.org to https.
 
 2019-09-09  Edward Smith-Rowland  <3dw4rd@verizon.net>
        PSTL backend if no TBB present.
        * testsuite/utils/pstl/test_utils.h: Remove check for
        _PSTL_USE_PAR_POLICIES
-       
+
 2019-06-07  Jonathan Wakely  <jwakely@redhat.com>
 
        * testsuite/24_iterators/container_access.cc: Move dg-options before
        Document PSTL linker flags
 
        * doc/xml/manual/using.xml: Add PSTL linker flags to table 3.1.
-       
+
 2019-04-23  Jonathan Wakely  <jwakely@redhat.com>
 
        * include/std/variant (__detail::__variant::_Traits): Make
 
        * include/bits/c++config: Remove explicit PSTL configuration
        macros and use definitions from <pstl/pstl_config.h>.
-       
+
 2019-04-20  Thomas Rodgers <trodgers@redhat.com>
 
        Cleanup algorithm implementations
        (equal): Qualify call to std::equal().
        (partial_sort): Forward execution policy.
        (inplace_merge): Forward execution policy.
-       
+
 2019-04-19  Thomas Rodgers <trodgers@redhat.com>
-       
+
        Improve implementation of parallel equal()
        * include/pstl/algorithm_impl.h
        (__internal::__brick_equal): use "4 iterator" version of
        * include/pstl/glue_algorithm_impl.h
        (std::equal): dispatch to "4 iterator" version of
        __internal::__pattern_equal().
-       
+
 2019-04-17  Jonathan Wakely  <jwakely@redhat.com>
 
        PR libstdc++/90105
        * testsuite/20_util/optional/observers/4.cc: Likewise.
 
 2019-04-12  Thomas Rodgers  <trodgers@redhat.com>
-       
+
        * include/pstl/algorithm_impl.h: Uglify identfiers.
        * include/pstl/numeric_impl.h:  Uglify identfiers.
        * include/pstl/parallel_backend_tbb.h: Uglify identfiers.
        avoid -Wconversion warnings.
 
 2019-03-21  Thomas Rodgers  <trodgers@redhat.com>
-       
+
        * include/Makefile.am (std_header): Add ${std_srcdir}/execution.
        (pstl_srcdir, pstl_builddir, pstl_headers): New variables.
        (allstamped): Add stamp-pstl.