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

--- Comment #4 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The trunk branch has been updated by Jason Merrill <ja...@gcc.gnu.org>:

https://gcc.gnu.org/g:32bab8b57ddf0df727f5eaf99a77e70882c4e6e2

commit r14-6764-g32bab8b57ddf0df727f5eaf99a77e70882c4e6e2
Author: Jason Merrill <ja...@redhat.com>
Date:   Tue Dec 19 15:33:07 2023 -0500

    opts: -Werror=foo always implies -Wfoo [PR106213]

    -Werror=foo implying -Wfoo wasn't working for -Wdeprecated-copy-dtor,
    because it is specified as the value 2 of warn_deprecated_copy, which shows
    up as CLVC_EQUAL, which is not one of the three var_types handled by
    control_warning_option.  It seems to me that we can just unconditionally
    handle_generated_option, and only have special argument handling for those
    types.

            PR c++/106213

    gcc/ChangeLog:

            * opts-common.cc (control_warning_option): Call
            handle_generated_option for all cl_var_types.

    gcc/testsuite/ChangeLog:

            * g++.dg/cpp0x/depr-copy5.C: New test.

Reply via email to