]> granicus.if.org Git - clang/commitdiff
[libclang] For c-index-test disable caching of code completion results if
authorArgyrios Kyrtzidis <akyrtzi@gmail.com>
Thu, 3 Nov 2011 02:20:25 +0000 (02:20 +0000)
committerArgyrios Kyrtzidis <akyrtzi@gmail.com>
Thu, 3 Nov 2011 02:20:25 +0000 (02:20 +0000)
the CINDEXTEST_COMPLETION_NO_CACHING environment variable is present.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@143604 91177308-0d34-0410-b5e6-96231b3b80d8

tools/c-index-test/c-index-test.c

index 80068b61568b8e9db2212c7046ea79c74eccdfdd..b46e3842a0d6c04ea2afc166756ba44156681040 100644 (file)
@@ -39,6 +39,8 @@ static unsigned getDefaultParsingOptions() {
     options |= CXTranslationUnit_CacheCompletionResults;
   if (getenv("CINDEXTEST_NESTED_MACROS"))
     options |= CXTranslationUnit_NestedMacroExpansions;
+  if (getenv("CINDEXTEST_COMPLETION_NO_CACHING"))
+    options &= ~CXTranslationUnit_CacheCompletionResults;
   
   return options;
 }