Really fix <rdar://problem/7312058> by adding a 'displayDiagnostics' option to
clang_createTranslationUnit() and clang_createTranslationUnitFromSourceFile(). The user can now
specify if the diagnostics from Clang are printed to stderr or are silenced completely. We can
obviously evolve this API to be more general in the future.

Note: Added a FIXME since I wasn't certain what was the best way to redirect to something analogous
to '/dev/null' on Windows.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@84548 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/tools/c-index-test/c-index-test.c b/tools/c-index-test/c-index-test.c
index fc84faa..29cd137 100644
--- a/tools/c-index-test/c-index-test.c
+++ b/tools/c-index-test/c-index-test.c
@@ -96,7 +96,7 @@
   if (!strcmp(argv[2], "local"))
     clang_wantOnlyLocalDeclarations(Idx);
 
-  TU = clang_createTranslationUnit(Idx, argv[1]);
+  TU = clang_createTranslationUnit(Idx, argv[1], /* displayDiagnostics= */ 1);
 
   if (!TU) {
     fprintf(stderr, "Unable to load translation unit!\n");