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

--- Comment #9 from Patrick Palka <ppalka at gcc dot gnu.org> ---
The master branch has been updated by Jason Merrill <ja...@gcc.gnu.org>:

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

commit r14-9946-gd435571b54b02946c97b5b24f20e5a7058fd96a1
Author: Jason Merrill <ja...@redhat.com>
Date:   Fri Apr 12 13:24:44 2024 -0400

    c++: reference list-init, conversion fn [PR113141]

    The original testcase in PR113141 is an instance of CWG1996; the standard
    fails to consider conversion functions when initializing a reference
    directly from an initializer-list of one element, but then does consider
    them when initializing a temporary.  I have a proposed fix for this defect,
    which is implemented here.

            DR 1996
            PR c++/113141

    gcc/cp/ChangeLog:

            * call.cc (reference_binding): Check direct binding from
            a single-element list.

    gcc/testsuite/ChangeLog:

            * g++.dg/cpp0x/initlist-ref1.C: New test.
            * g++.dg/cpp0x/initlist-ref2.C: New test.
            * g++.dg/cpp0x/initlist-ref3.C: New test.

    Co-authored-by: Patrick Palka <ppa...@redhat.com>

Reply via email to