[cfe-dev] How to silence warnings from system headers

Christian Gagneraud via cfe-dev cfe-dev at lists.llvm.org
Sun Jan 19 15:56:48 PST 2020


On Mon, 20 Jan 2020 at 07:10, Andrew Reece via cfe-dev
<cfe-dev at lists.llvm.org> wrote:
>
> Hi clang people,
>
> I'm using clang as a frontend for the LLVM ORC JIT on Windows.
> When I include system headers I get long error messages. For example, with stdlib.h I get a lot of: "warning: macro expansion producing 'defined' has undefined behavior"
>
> Is there a way to prevent these warnings? Preferably only for the system libraries.

Use `-isystem` instead of `-I` ?

Chris


More information about the cfe-dev mailing list