On 08/11/20 15:27 +0100, François Dumont via Libstdc++ wrote:
Following a recent fix on std::array this test started to fail in
_GLIBCXX_DEBUG mode.
FAIL: 23_containers/array/comparison_operators/96851.cc (test for
excess errors)
Rather than fixing it and now that __glibcxx_assert is constexpr
compatible I would like to propose to simply remove
__gnu_debug::array.
The only code we are losing with this change are the
_Array_check_nonempty/_Array_check_subscript types. I am not sure
about the purpose of this code as I saw no impact on tests. Maybe it
was to avoid assertion in constexpr where the value of the expression
is not use but there is a test doing that and it does produce an
assertion.
Note that I am also moving std::array in versioned namespace. It is
just for consistency so no problem to remove it.
I also manually edited include/Makefile.in cause I do not have the
proper autoreconf version. Can you regenerate it on your side once
patch is in ?
   libstdc++: Remove <debug/array>
   Add _GLIBCXX_ASSERTIONS assert in normal std::array and remove
__gnu_debug::array
   implementation.
   libstdc++-v3/ChangeLog:
           * include/debug/array: Remove.
           * include/Makefile.am: Remove <debug/array>.
           * include/Makefile.in: Regenerate.
           * include/experimental/functional: Adapt.
           * include/std/array: Move to _GLIBCXX_INLINE_VERSION
namespace.
           * include/std/functional: Adapt.
           * include/std/span: Adapt.
           * testsuite/23_containers/array/debug/back1_neg.cc:
           Remove dg-require-debug-mode. Add -D_GLIBCXX_ASSERTIONS
option.
           * testsuite/23_containers/array/debug/back2_neg.cc:
Likewise.
           * testsuite/23_containers/array/debug/front1_neg.cc:
Likewise.
           * testsuite/23_containers/array/debug/front2_neg.cc:
Likewise.
           *
testsuite/23_containers/array/debug/square_brackets_operator1_neg.cc:
           Likewise.
           *
testsuite/23_containers/array/debug/square_brackets_operator2_neg.cc:
           Likewise.
           * testsuite/23_containers/array/element_access/60497.cc
           *
testsuite/23_containers/array/tuple_interface/get_debug_neg.cc:
           Remove.
           *
testsuite/23_containers/array/tuple_interface/get_neg.cc
           *
testsuite/23_containers/array/tuple_interface/tuple_element_debug_neg.cc
           *
testsuite/23_containers/array/tuple_interface/tuple_element_neg.cc
Tested under Linux x86_64 normal and debug modes.
Ok to commit ?
Yes, this is a nice simplification, thanks.