Run DCE after a LoopFlatten test to reduce spurious output [nfc]
[llvm-project.git] / clang / test / Index / codecompletion-chained.cpp
blob40454d2771789e9a4dd84e36abbde360788190f3
1 #ifndef HEADER1
2 #define HEADER1
4 // CHECK-TU: FunctionDecl:{ResultType void}{TypedText foo}
5 void foo();
7 namespace Cake {
8 // CHECK-NAMESPACE: FunctionDecl:{ResultType void}{TypedText lie}
9 void lie();
12 #elif !defined(HEADER2)
13 #define HEADER2
15 namespace Cake {
16 extern int Baz;
19 #else
21 void func() {
22 Cake::
25 #endif
27 // RUN: c-index-test -write-pch %t1.h.pch %s
28 // RUN: c-index-test -write-pch %t2.h.pch %s -include %t1.h
29 // RUN: c-index-test -code-completion-at=%s:22:1 %s -include %t2.h | FileCheck -check-prefix=CHECK-TU %s
30 // RUN: c-index-test -code-completion-at=%s:22:7 %s -include %t2.h | FileCheck -check-prefix=CHECK-NAMESPACE %s