This is the mail archive of the gcc-patches@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]

Re: simple fix for a few warning (0).


Manuel López-Ibáñez wrote:
> :ADDPATCH C/C++:


> 2007-01-29  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
> 
>  * c-decl.c (pop_scope): Replace warnings with call to
> warn_for_unused_label.
>  * c-common.h (warn_for_unused_label): Declare.
>  * c-common.c (warn_for_unused_label): Define.
> 
> cp/
> 2007-01-29  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>
> 
>  * decl.c (pop_label): Replace warning with call to warn_for_unused_label.

:REVIEWMAIL: OK

With one change. :-)

> +void
> +warn_for_unused_label (tree label)

All functions need a comment.  For this function:

  /* If LABEL (a LABEL_DECL) has not been used, issue a warning.  */

would be fine.  The comment should mention all parameters by name.

Thanks,

-- 
Mark Mitchell
CodeSourcery
mark@codesourcery.com
(650) 331-3385 x713


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