[cfe-dev] Making analyzer warnings fatal

Keno Fischer via cfe-dev cfe-dev at lists.llvm.org
Mon Jun 3 11:20:30 PDT 2019


Hi everyone,

for the Julia source code, we have custom clang analyzer plugin that
validates certain GC invariants (GC frame management, making sure
values are rooted across safepoints, etc) in our runtime library [1].
We've now started running this on CI, but we noticed that newly
introduced errors don't actually cause the clang process to return a
non-zero exit code and are thus indistinguishable from a clean
analysis result. Is there a way to turn analyzer warnings into errors?
We tried `-Werror`, but that gets explicitly filtered when the
analyzer is used. There's probably something obvious we're missing,
but I didn't see anything even scanning through the source code.

Thanks,
Keno


[1] https://github.com/JuliaLang/julia/blob/master/src/clangsa/GCChecker.cpp



More information about the cfe-dev mailing list