This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc 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: -Werror now enabled by default


On Thu, 11 Dec 2014, Stefan Liebler wrote:

> Removing the inline from maybe_swap_uint32 in locfile.h leads to:
> gcc ../locale/programs/linereader.c -c ...
> In file included from ../locale/programs/linereader.c:35:0:
> ../locale/programs/locfile.h:89:1: error: ‘maybe_swap_uint32’ defined but not
> used [-Werror=unused-function]
>  maybe_swap_uint32 (uint32_t value)
>  ^
> cc1: all warnings being treated as errors

So use __attribute__ ((unused)) to avoid that error.

-- 
Joseph S. Myers
joseph@codesourcery.com

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