gcc/libstdc++-v3/include
Patrick Palka ce33801fe4 libstdc++: Fix bogus use of memcmp in ranges::lexicographical_compare (PR 93972)
We were enabling the memcmp optimization in ranges::lexicographical_compare for
signed integral types and for integral types wider than a byte.  But memcmp
gives the wrong answer for arrays of such types.  This patch fixes this issue by
refining the condition that enables the memcmp optimization.  It's now
consistent with the corresponding condition used in
std::lexicographical_compare.

libstdc++-v3/ChangeLog:

	PR libstdc++/93972
	* include/bits/ranges_algo.h (__lexicographical_compare_fn::operator()):
	Fix condition for when to use memcmp, making it consistent with the
	corresponding condition used in std::lexicographical_compare.
	* testsuite/25_algorithms/lexicographical_compare/93972.cc: New test.
2020-02-28 17:55:44 -05:00
..
backward
bits libstdc++: Fix bogus use of memcmp in ranges::lexicographical_compare (PR 93972) 2020-02-28 17:55:44 -05:00
c
c_compatibility
c_global
c_std
debug libstdc++: Define <=> for Debug Mode array 2020-02-27 15:13:16 +00:00
decimal
experimental libstdc++: enable_view has false positives (LWG 3326) 2020-02-24 12:15:05 +00:00
ext libstdc++: Implement P1878R1 "Constraining Readable Types" 2020-02-07 16:58:43 +00:00
parallel
precompiled
pstl
std libstdc++: Also disable caching of reverse_view::begin() for common_ranges 2020-02-28 11:55:58 -05:00
tr1
tr2
Makefile.am libstdc++: Add lightweight replacement for std::numeric_limits (PR 92546) 2020-02-17 15:11:04 +00:00
Makefile.in libstdc++: Add lightweight replacement for std::numeric_limits (PR 92546) 2020-02-17 15:11:04 +00:00