Implement clang_saveTranslationUnit(), which saves a translation unit
into a PCH/AST file.


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@111006 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/test/Index/preamble.c b/test/Index/preamble.c
index c285cd2..1d3e7e8 100644
--- a/test/Index/preamble.c
+++ b/test/Index/preamble.c
@@ -5,7 +5,7 @@
 void f(int x) {
   
 }
-// RUN: %clang -x c-header -o %t.pch %S/Inputs/prefix.h
+// RUN: c-index-test -write-pch %t.pch -x c-header %S/Inputs/prefix.h
 // RUN: env CINDEXTEST_EDITING=1 c-index-test -test-load-source-reparse 5 local -I %S/Inputs -include %t %s 2> %t.stderr.txt | FileCheck %s
 // RUN: FileCheck -check-prefix CHECK-DIAG %s < %t.stderr.txt
 // CHECK: preamble.h:1:12: FunctionDecl=bar:1:12 (Definition) Extent=[1:12 - 6:2]