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

--- Comment #2 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Patrick Palka <ppa...@gcc.gnu.org>:

https://gcc.gnu.org/g:e7930c6750d03b28d922ebbbace20ba9d8622c6a

commit r13-5682-ge7930c6750d03b28d922ebbbace20ba9d8622c6a
Author: Patrick Palka <ppa...@redhat.com>
Date:   Fri Feb 3 09:12:31 2023 -0500

    c++: excessive satisfaction in check_methods [PR108579]

    In check_methods we're unnecessarily checking satisfaction for all
    constructors and assignment operators, even those that don't look like
    copy/move special members.  In the testcase below this manifests as an
    unstable satisfaction error because the satisfaction result is first
    determined to be false during check_methods (since A<int> is incomplete
    at this point) and later true after completion of A<int>.

    This patch fixes this simply by swapping the order of the
    constraint_satisfied_p and copy/move_fn_p tests.

            PR c++/108579

    gcc/cp/ChangeLog:

            * class.cc (check_methods): Swap order of constraints_satisfied_p
            and copy/move_fn_p tests.

    gcc/testsuite/ChangeLog:

            * g++.dg/cpp2a/concepts-pr108579.C: New test.

Reply via email to