This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/69818] warn for C++ functional cast expression on pointer or reference


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

Manuel LÃpez-IbÃÃez <manu at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |diagnostic, easyhack
                 CC|                            |manu at gcc dot gnu.org
            Summary|feature request: generate a |warn for C++ functional
                   |warning for C++ functional  |cast expression on pointer
                   |cast expression on pointer  |or reference
                   |or reference                |

--- Comment #4 from Manuel LÃpez-IbÃÃez <manu at gcc dot gnu.org> ---
(In reply to Chris Studholme from comment #3)
> Does the same rational for -Wold-style-cast not apply here?  Another option
> might be to extend -Wold-style-cast to cover these problematic uses of
> functional casts, instead of adding a new warning.

I would say that this is indeed preferable. Of course, it will depend on who
actually implements this.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]