xref: /minix3/external/bsd/llvm/dist/clang/test/Index/complete-unterminated.c (revision f4a2713ac843a11c696ec80c0a5e3e5d80b4d338)
1*f4a2713aSLionel Sambuc typedef int Integer;
2*f4a2713aSLionel Sambuc 
3*f4a2713aSLionel Sambuc #if 0
4*f4a2713aSLionel Sambuc 
5*f4a2713aSLionel Sambuc 
6*f4a2713aSLionel Sambuc #endif
7*f4a2713aSLionel Sambuc 
8*f4a2713aSLionel Sambuc /* blah */
9*f4a2713aSLionel Sambuc 
10*f4a2713aSLionel Sambuc void f0(const char*);
11*f4a2713aSLionel Sambuc void f1(char);
12*f4a2713aSLionel Sambuc 
13*f4a2713aSLionel Sambuc const char *hello = "Hello, world";
14*f4a2713aSLionel Sambuc const char a = 'a';
15*f4a2713aSLionel Sambuc 
16*f4a2713aSLionel Sambuc #define FOO(a, b) a b
17*f4a2713aSLionel Sambuc 
18*f4a2713aSLionel Sambuc FOO(int, x);
19*f4a2713aSLionel Sambuc 
20*f4a2713aSLionel Sambuc // RUN: c-index-test -code-completion-at=%s:5:1 -pedantic %s 2> %t.err | FileCheck %s
21*f4a2713aSLionel Sambuc // RUN: not grep error %t.err
22*f4a2713aSLionel Sambuc // CHECK: {TypedText Integer}
23*f4a2713aSLionel Sambuc // RUN: c-index-test -code-completion-at=%s:8:6 -pedantic %s 2> %t.err
24*f4a2713aSLionel Sambuc // RUN: not grep error %t.err
25*f4a2713aSLionel Sambuc // RUN: c-index-test -code-completion-at=%s:10:28 -pedantic %s 2> %t.err
26*f4a2713aSLionel Sambuc // RUN: not grep unterminated %t.err
27*f4a2713aSLionel Sambuc // RUN: c-index-test -code-completion-at=%s:11:17 -pedantic %s 2> %t.err
28*f4a2713aSLionel Sambuc // RUN: not grep unterminated %t.err
29*f4a2713aSLionel Sambuc // RUN: c-index-test -code-completion-at=%s:18:10 -pedantic %s 2> %t.err
30*f4a2713aSLionel Sambuc // RUN: not grep unterminated %t.err
31