https://gcc.gnu.org/bugzilla/show_bug.cgi?id=119714
--- Comment #13 from GCC Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Patrick Palka <[email protected]>: https://gcc.gnu.org/g:35d754588329660ea297bca621747840bffbc7e5 commit r16-8740-g35d754588329660ea297bca621747840bffbc7e5 Author: Patrick Palka <[email protected]> Date: Fri Apr 17 11:19:58 2026 -0400 libstdc++: Fix constraint recursion in std::indirect's operator== [PR124890] Like in r16-559 for std::expected, std::indirect's operator== is also prone to constraint recursion due to CWG 2369, for the Mandates that we implement as an associated constraint. This patch works around the recursion in a similar manner as done for std::expected (and std::basic_const_iterator). PR libstdc++/124890 PR libstdc++/119714 PR libstdc++/112490 libstdc++-v3/ChangeLog: * include/bits/indirect.h (indirect::operator==): Replace non-dependent std::indirect function parameter with a dependent one of type indirect<_Vp> where _Vp matches _Tp. * testsuite/std/memory/indirect/124890.cc: New test. Reviewed-by: Jonathan Wakely <[email protected]>
