https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115799

--- Comment #6 from GCC 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:ce34fcc572a0dceebcffef76e98064546feebb38

commit r15-1880-gce34fcc572a0dceebcffef76e98064546feebb38
Author: Jonathan Wakely <jwak...@redhat.com>
Date:   Sat Jul 6 21:34:29 2024 +0100

    libstdc++: Fix std::find for non-contiguous iterators [PR115799]

    The r15-1857 change didn't correctly restrict the new optimization to
    contiguous iterators.

    libstdc++-v3/ChangeLog:

            PR libstdc++/115799
            * include/bits/stl_algo.h (find): Use 'if constexpr' so that
            memchr optimization is a discarded statement for non-contiguous
            iterators.
            * testsuite/25_algorithms/find/bytes.cc: Check with input
            iterators.

Reply via email to