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++/68230] Unused function parameters not reported by -Wunused-parameter when only used recursively.


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

--- Comment #2 from Jonathan Wakely <redi at gcc dot gnu.org> ---
I'm not sure there *should* be a warning here.

I find -Wunused-parameter most useful to know when I can remove the name of the
parameter, but you can't do that here (because it still needs a name to pass it
to the recursive call).

It's rare that my reaction to a -Wunused-parameter warning is to change the
function to remove the parameter entirely. YMMV.

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