summaryrefslogtreecommitdiffstats
path: root/test/Index/load-exprs.c
diff options
context:
space:
mode:
authorrdivacky <rdivacky@FreeBSD.org>2010-01-23 11:10:26 +0000
committerrdivacky <rdivacky@FreeBSD.org>2010-01-23 11:10:26 +0000
commit2fce988e86bc01829142e4362d4eff1af0925147 (patch)
treec69d3f4f13d508570bb5257a6aea735f88bdf09c /test/Index/load-exprs.c
parenta3fa5c7f1b5e2ba4d6ec033dc0e2376326b05824 (diff)
downloadFreeBSD-src-2fce988e86bc01829142e4362d4eff1af0925147.zip
FreeBSD-src-2fce988e86bc01829142e4362d4eff1af0925147.tar.gz
Update clang to r94309.
Diffstat (limited to 'test/Index/load-exprs.c')
-rw-r--r--test/Index/load-exprs.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/test/Index/load-exprs.c b/test/Index/load-exprs.c
new file mode 100644
index 0000000..a360efd
--- /dev/null
+++ b/test/Index/load-exprs.c
@@ -0,0 +1,13 @@
+typedef int T;
+struct X { int a, b; };
+void f(void *ptr) {
+ T* t_ptr = (T *)ptr;
+ (void)sizeof(T);
+ struct X x = (struct X){1, 2};
+}
+
+// RUN: c-index-test -test-load-source all %s | FileCheck %s
+
+// CHECK: load-exprs.c:4:15: TypeRef=T:1:13 [Extent=4:15:4:15]
+// CHECK: load-exprs.c:5:16: TypeRef=T:1:13 [Extent=5:16:5:16]
+// FIXME: the source location for "struct X" points at "struct", not "X"
OpenPOWER on IntegriCloud