mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-04-28 13:51:16 +08:00
LWG 3324 changed the [cmp.alg] types to use std::compare_three_way instead of the <=> operator, but we were still using the old specification. In order to make the existing tests pass the N::X type needs to be equality comparable, so that three_way_comparable is satisfied and compare_three_way can be used. As part of this change I noticed that the compare_three_way call operator was unconditionally noexcept, which is incorrect. * libsupc++/compare (compare_three_way): Fix noexcept-specifier. (strong_order, weak_order, partial_order): Replace uses of <=> with compare_three_way function object (LWG 3324). * testsuite/18_support/comparisons/algorithms/partial_order.cc: Add equality operator so that X satisfies three_way_comparable. * testsuite/18_support/comparisons/algorithms/strong_order.cc: Likewise. * testsuite/18_support/comparisons/algorithms/weak_order.cc: Likewise.
file: libstdc++-v3/README New users may wish to point their web browsers to the file index.html in the 'doc/html' subdirectory. It contains brief building instructions and notes on how to configure the library in interesting ways.