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

--- Comment #3 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Nathaniel Shead <nsh...@gcc.gnu.org>:

https://gcc.gnu.org/g:49d83e963aa453600088380aebd507e172eb80ad

commit r14-9332-g49d83e963aa453600088380aebd507e172eb80ad
Author: Nathaniel Shead <nathanielosh...@gmail.com>
Date:   Wed Mar 6 00:43:22 2024 +1100

    c++: Fix template deduction for conversion operators with xobj parameters
[PR113629]

    Unification for conversion operators (DEDUCE_CONV) doesn't perform
    transformations like handling forwarding references. This is correct in
    general, but not for xobj parameters, which should be handled "normally"
    for the purposes of deduction: [temp.deduct.conv] only applies to the
    return type of the conversion function.

            PR c++/113629

    gcc/cp/ChangeLog:

            * pt.cc (type_unification_real): Only use DEDUCE_CONV for the
            return type of a conversion function.

    gcc/testsuite/ChangeLog:

            * g++.dg/cpp23/explicit-obj-conv-op.C: New test.

    Signed-off-by: Nathaniel Shead <nathanielosh...@gmail.com>
    Reviewed-by: Jason Merrill <ja...@redhat.com>
  • [Bug c++/113629] 'deducing this... cvs-commit at gcc dot gnu.org via Gcc-bugs

Reply via email to