aboutsummaryrefslogtreecommitdiff
path: root/clang/tools/c-index-test/c-index-test.c
diff options
context:
space:
mode:
authorNikolai Kosjar <nikolai.kosjar@qt.io>2019-06-11 14:14:24 +0000
committerNikolai Kosjar <nikolai.kosjar@qt.io>2019-06-11 14:14:24 +0000
commit8edd8da4874d79e07a6398088d6831b74758dbc2 (patch)
tree670318825b057b29721c55872b0503cf0c2411e4 /clang/tools/c-index-test/c-index-test.c
parent9487963244e4c805cf0f5798d903bdb10012b59d (diff)
downloadllvm-8edd8da4874d79e07a6398088d6831b74758dbc2.zip
llvm-8edd8da4874d79e07a6398088d6831b74758dbc2.tar.gz
llvm-8edd8da4874d79e07a6398088d6831b74758dbc2.tar.bz2
[libclang] Allow skipping warnings from all included files
Depending on the included files and the used warning flags, e.g. - Weverything, a huge number of warnings can be reported for included files. As processing that many diagnostics comes with a performance impact and not all clients are interested in those diagnostics, add a flag to skip them. Differential Revision: https://reviews.llvm.org/D48116 llvm-svn: 363067
Diffstat (limited to 'clang/tools/c-index-test/c-index-test.c')
-rw-r--r--clang/tools/c-index-test/c-index-test.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/clang/tools/c-index-test/c-index-test.c b/clang/tools/c-index-test/c-index-test.c
index 42fd0bb..4032631 100644
--- a/clang/tools/c-index-test/c-index-test.c
+++ b/clang/tools/c-index-test/c-index-test.c
@@ -88,6 +88,8 @@ static unsigned getDefaultParsingOptions() {
options |= CXTranslationUnit_IncludeAttributedTypes;
if (getenv("CINDEXTEST_VISIT_IMPLICIT_ATTRIBUTES"))
options |= CXTranslationUnit_VisitImplicitAttributes;
+ if (getenv("CINDEXTEST_IGNORE_NONERRORS_FROM_INCLUDED_FILES"))
+ options |= CXTranslationUnit_IgnoreNonErrorsFromIncludedFiles;
return options;
}