| 1 |
// RUN: rm -rf %t |
| 2 |
// RUN: %clang_cc1 -extract-api --pretty-sgf --emit-sgf-symbol-labels-for-testing \ |
| 3 |
// RUN: -triple arm64-apple-macosx -x objective-c-header %s -o %t/output.symbols.json |
| 4 |
|
| 5 |
_Pragma("clang assume_nonnull begin") |
| 6 |
|
| 7 |
struct Foo { int a; }; |
| 8 |
typedef struct Foo *Bar; |
| 9 |
// RUN: FileCheck %s -input-file %t/output.symbols.json --check-prefix FUNC |
| 10 |
void func(Bar b); |
| 11 |
// FUNC-LABEL: "!testLabel": "c:@F@func", |
| 12 |
// CHECK-NOT: Foo |
| 13 |
// CHECK: "pathComponents" |
| 14 |
|
| 15 |
// RUN: FileCheck %s --input-file %t/output.symbols.json --check-prefix THING |
| 16 |
#define SWIFT_NAME(_name) __attribute__((swift_name(#_name))) |
| 17 |
extern Bar const thing SWIFT_NAME(swiftThing); |
| 18 |
// THING-LABEL: "!testLabel": "c:@thing" |
| 19 |
// THING-NOT: Foo |
| 20 |
// THING: "pathComponents" |
| 21 |
|
| 22 |
_Pragma("clang assume_nonnull end") |
| 23 |
|
| 24 |
// expected-no-diagnostics |