aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorPatrick Palka <ppalka@redhat.com>2025-05-12 09:15:34 -0400
committerPatrick Palka <ppalka@redhat.com>2025-05-12 09:23:49 -0400
commit0b76b58a5875d519f95a5af661fb64e42a42ed8e (patch)
treea62ba498ea97a43c9536e7088a5f4571eb4eddf0 /gcc
parent0ff3b3122adfe0c479901da4fc28e367d89f185b (diff)
downloadgcc-0b76b58a5875d519f95a5af661fb64e42a42ed8e.zip
gcc-0b76b58a5875d519f95a5af661fb64e42a42ed8e.tar.gz
gcc-0b76b58a5875d519f95a5af661fb64e42a42ed8e.tar.bz2
libstdc++: Fix constraint recursion in std::expected's operator== [PR119714]
This std::expected friend operator== is prone to constraint recursion after CWG 2369 for the same reason as basic_const_iterator's comparison operators were before the r15-7757-g4342c50ca84ae5 workaround. This patch works around the constraint recursion here in a similar manner, by making the function parameter of type std::expected dependent in a trivial way. PR libstdc++/119714 PR libstdc++/112490 libstdc++-v3/ChangeLog: * include/std/expected (expected::operator==): Replace non-dependent std::expected function parameter with a dependent one of type expected<_Vp, _Er> where _Vp matches _Tp. * testsuite/20_util/expected/119714.cc: New test. Reviewed-by: Tomasz KamiƄski <tkaminsk@redhat.com> Reviewed-by: Jonathan Wakely <jwakely@redhat.com> (cherry picked from commit 91bc8169edd9038d78f38bd813287d72e6345c26)
Diffstat (limited to 'gcc')
0 files changed, 0 insertions, 0 deletions