[cfe-users] static inline functions in headers and -Wunused-function

Rainer Gerhards via cfe-users cfe-users at lists.llvm.org
Wed Jan 27 03:01:14 PST 2016

Hi all,

I try to use -Werror -Wall for my project, which includes -Wunused-function.

Unfortunately, I receive a couple of warnings from library header files
which include

static inline ... func() { ... }

These functions are indeed often unused, but as of my understanding this
should be perfectly fine with static inline functions (they just replace
macro definitions in a better way).

Am I wrong here? What's the best path to fix this?

version: Ubuntu clang version 3.6.2-1 (tags/RELEASE_362/final) (based on
LLVM 3.6.2)

Any help is deeply appreciated.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-users/attachments/20160127/ccd4b048/attachment.html>

More information about the cfe-users mailing list