1 // RUN: c-index-test -index-file %s -target armv7-windows-gnu -fdeclspec | FileCheck %s
3 struct __declspec(dllexport
) export_s
{
6 // CHECK: [indexDeclaration]: kind: struct | name: export_s | {{.*}} | lang: C++
7 // CHECK: <attribute>: attribute(dllexport)
8 // CHECK: [indexDeclaration]: kind: c++-instance-method | name: m | {{.*}} | lang: C++
9 // CHECK: <attribute>: attribute(dllexport)
11 struct __declspec(dllimport
) import_s
{
14 // CHECK: [indexDeclaration]: kind: struct | name: import_s | {{.*}} | lang: C++
15 // CHECK: <attribute>: attribute(dllimport)
16 // CHECK: [indexDeclaration]: kind: c++-instance-method | name: m | {{.*}} | lang: C++
17 // CHECK: <attribute>: attribute(dllimport)
19 class __attribute__((dllexport
)) export_gnu_s
{
22 // CHECK: [indexDeclaration]: kind: c++-class | name: export_gnu_s | {{.*}} | lang: C++
23 // CHECK: <attribute>: attribute(dllexport)
24 // CHECK: [indexDeclaration]: kind: c++-instance-method | name: m | {{.*}} | lang: C++
25 // CHECK: <attribute>: attribute(dllexport)
27 class __attribute__((dllimport
)) import_gnu_s
{
30 // CHECK: [indexDeclaration]: kind: c++-class | name: import_gnu_s | {{.*}} | lang: C++
31 // CHECK: <attribute>: attribute(dllimport)
32 // CHECK: [indexDeclaration]: kind: c++-instance-method | name: m | {{.*}} | lang: C++
33 // CHECK: <attribute>: attribute(dllimport)
35 extern "C" void __declspec(dllexport
) export_function(void) {}
36 // CHECK: [indexDeclaration]: kind: function | name: export_function | {{.*}} | lang: C
37 // CHECK: <attribute>: attribute(dllexport)
38 extern "C" void __attribute__((dllexport
)) export_gnu_function(void) {}
39 // CHECK: [indexDeclaration]: kind: function | name: export_gnu_function | {{.*}} | lang: C
40 // CHECK: <attribute>: attribute(dllexport)
43 void __declspec(dllimport
) import_function(void);
44 // CHECK: [indexDeclaration]: kind: function | name: import_function | {{.*}} | lang: C
45 // CHECK: <attribute>: attribute(dllimport)
46 void __attribute__((dllimport
)) import_gnu_function(void);
47 // CHECK: [indexDeclaration]: kind: function | name: import_gnu_function | {{.*}} | lang: C
48 // CHECK: <attribute>: attribute(dllimport)