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

--- Comment #13 from Marek Polacek <mpolacek at gcc dot gnu.org> ---
Author: mpolacek
Date: Sat Sep 28 15:35:37 2019
New Revision: 276251

URL: https://gcc.gnu.org/viewcvs?rev=276251&root=gcc&view=rev
Log:
        PR c++/91889 - follow-up fix for DR 2352.
        * call.c (involves_qualification_conversion_p): New function.
        (direct_reference_binding): Build a ck_qual if the conversion
        would involve a qualification conversion.
        (convert_like_real): Strip the conversion created by the ck_qual
        in direct_reference_binding.

        * g++.dg/cpp0x/ref-bind3.C: Add dg-error.
        * g++.dg/cpp0x/ref-bind4.C: New test.
        * g++.dg/cpp0x/ref-bind5.C: New test.
        * g++.dg/cpp0x/ref-bind6.C: New test.
        * g++.old-deja/g++.pt/spec35.C: Revert earlier change.

Added:
    trunk/gcc/testsuite/g++.dg/cpp0x/ref-bind4.C
    trunk/gcc/testsuite/g++.dg/cpp0x/ref-bind5.C
    trunk/gcc/testsuite/g++.dg/cpp0x/ref-bind6.C
Modified:
    trunk/gcc/cp/ChangeLog
    trunk/gcc/cp/call.c
    trunk/gcc/testsuite/ChangeLog
    trunk/gcc/testsuite/g++.dg/cpp0x/ref-bind3.C
    trunk/gcc/testsuite/g++.old-deja/g++.pt/spec35.C

Reply via email to