diff options
Diffstat (limited to 'test/Index/cindex-from-source.m')
-rw-r--r-- | test/Index/cindex-from-source.m | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/test/Index/cindex-from-source.m b/test/Index/cindex-from-source.m new file mode 100644 index 0000000..8d6a1de --- /dev/null +++ b/test/Index/cindex-from-source.m @@ -0,0 +1,9 @@ +// RUN: echo 'typedef int t0;' > %t.pfx.h +// RUN: clang -x objective-c-header %t.pfx.h -o %t.pfx.h.gch +// RUN: c-index-test -test-load-source local %s -include %t.pfx.h > %t +// RUN: FileCheck %s < %t +// CHECK: cindex-from-source.m:{{.*}}:{{.*}}: StructDecl=s0:{{.*}}:{{.*}} [Context=cindex-from-source.m] +// CHECK: cindex-from-source.m:{{.*}}:{{.*}}: VarDecl=g0:{{.*}}:{{.*}} [Context=cindex-from-source.m] + +struct s0 {}; +t0 g0; |