llvm-project/clang/test/Index/index-attrs.c

17 lines
853 B
C
Raw Normal View History

2017-05-11 16:25:22 +08:00
// RUN: c-index-test -index-file -check-prefix CHECK %s -target armv7-windows-gnu -fdeclspec
void __declspec(dllexport) export_function(void) {}
2017-05-11 16:25:22 +08:00
// CHECK: [indexDeclaraton]: kind: function | name: export_function | {{.*}} | lang: C
// CHECK: <attribute>: attribute(dllexport)
void __attribute__((dllexport)) export_gnu_attribute(void) {}
2017-05-11 16:25:22 +08:00
// CHECK: [indexDeclaration] kind: function | name: export_gnu_attribute | {{.*}} | lang: C
// CHECK: <attribute>: attribute(dllexport)
void __declspec(dllimport) import_function(void);
2017-05-11 16:25:22 +08:00
// CHECK: [indexDeclaration] kind: function | name: import_function | {{.*}} | lang: C
// CHECK: <attribute>: attribute(dllimport)
void __attribute__((dllimport)) import_gnu_attribute(void);
2017-05-11 16:25:22 +08:00
// CHECK: [indexDeclaration] kind: function | name: import_gnu_function | {{.*}} | lang: C
// CHECK: <attribute>: attribute(dllimport)