Argyrios Kyrtzidis | 25893e0 | 2012-10-31 17:29:22 +0000 | [diff] [blame] | 1 | |
| 2 | // This is to make sure we skip function bodies. |
| 3 | void func_to_skip() { |
| 4 | undeclared1 = 0; |
| 5 | } |
| 6 | |
| 7 | struct S { int x; }; |
| 8 | |
| 9 | void func(S *s) { |
| 10 | undeclared2 = 0; |
| 11 | s->x = 0; |
| 12 | } |
| 13 | |
| 14 | // RUN: c-index-test -code-completion-at=%s:11:6 %s 2>&1 | FileCheck %s |
| 15 | // CHECK-NOT: error: use of undeclared identifier 'undeclared1' |
| 16 | // CHECK: error: use of undeclared identifier 'undeclared2' |
| 17 | // CHECK: FieldDecl:{ResultType int}{TypedText x} |
NAKAMURA Takumi | bef17f9 | 2012-11-01 00:20:00 +0000 | [diff] [blame^] | 18 | |
| 19 | // FIXME: Investigating |
| 20 | // XFAIL: cygwin,mingw32,win32 |