aboutsummaryrefslogtreecommitdiff
path: root/test/Index/complete-stmt.c
diff options
context:
space:
mode:
Diffstat (limited to 'test/Index/complete-stmt.c')
-rw-r--r--test/Index/complete-stmt.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/test/Index/complete-stmt.c b/test/Index/complete-stmt.c
new file mode 100644
index 000000000000..98fa9df44db3
--- /dev/null
+++ b/test/Index/complete-stmt.c
@@ -0,0 +1,12 @@
+// Note: the run lines follow their respective tests, since line/column
+// matter in this test.
+
+
+void f(int x) {
+ if (x) {
+ }
+}
+
+// RUN: c-index-test -code-completion-at=%s:7:4 %s | FileCheck -check-prefix=CHECK-IF-ELSE %s
+// CHECK-IF-ELSE: NotImplemented:{TypedText else}{HorizontalSpace }{LeftBrace {}{VerticalSpace }{Placeholder statements}{VerticalSpace }{RightBrace }} (40)
+// CHECK-IF-ELSE: NotImplemented:{TypedText else}{HorizontalSpace }{Text if}{HorizontalSpace }{LeftParen (}{Placeholder expression}{RightParen )}{HorizontalSpace }{LeftBrace {}{VerticalSpace }{Placeholder statements}{VerticalSpace }{RightBrace }} (40)