https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93972
--- Comment #4 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Jonathan Wakely <r...@gcc.gnu.org>: https://gcc.gnu.org/g:d112e173ea093f55a16a14b26ef65088381ee09c commit r10-6975-gd112e173ea093f55a16a14b26ef65088381ee09c Author: Jonathan Wakely <jwak...@redhat.com> Date: Mon Mar 2 17:03:28 2020 +0000 libstdc++: Fix std::lexicographic_compare for unsigned char (PR 93972) The new 25_algorithms/lexicographical_compare/93972.cc test fails on targets where char is unsigned, revealing an existing regression with the std::__memcmp helper that had gone unnoticed in std::lexicographical_compare. When comparing char and unsigned char, the memcmp optimisation is enabled, but the new std::__memcmp function fails to compile for mismatched types. PR libstdc++/93972 * include/bits/stl_algobase.h (__memcmp): Allow pointer types to differ. * testsuite/25_algorithms/lexicographical_compare/uchar.cc: New test.