[clang] Handle __declspec() attributes in using
[llvm-project.git] / clang / test / PCH / chain-late-anonymous-namespace.cpp
blobedae285c9084eeff0d0a63f6d0ae8c289fccf366
1 // no PCH
2 // RUN: %clang_cc1 -include %s -include %s -fsyntax-only %s
3 // with PCH
4 // RUN: %clang_cc1 -chain-include %s -chain-include %s -fsyntax-only %s
5 // with PCH, with modules enabled
6 // RUN: %clang_cc1 -chain-include %s -chain-include %s -fsyntax-only -fmodules %s
7 #if !defined(PASS1)
8 #define PASS1
10 namespace ns {}
11 namespace os {}
13 #elif !defined(PASS2)
14 #define PASS2
16 namespace ns {
17 namespace {
18 extern int x;
22 namespace {
23 extern int y;
25 namespace {
28 namespace os {
29 extern "C" {
30 namespace {
31 extern int z;
36 #else
38 namespace ns {
39 namespace {
40 int x;
42 void test() {
43 (void)x;
47 namespace {
48 int y;
50 void test() {
51 (void)y;
54 namespace os {
55 namespace {
56 int z;
58 void test() {
59 (void)z;
63 #endif