| 1 |
#define CF_SWIFT_NAME(_name) __attribute__((swift_name(#_name))) |
| 2 |
|
| 3 |
#include <stdarg.h> |
| 4 |
#include <stdbool.h> |
| 5 |
#include <stdint.h> |
| 6 |
#include <stdlib.h> |
| 7 |
|
| 8 |
typedef struct Opaque Opaque; |
| 9 |
|
| 10 |
typedef struct SelfTypeTestStruct { |
| 11 |
uint8_t times; |
| 12 |
} SelfTypeTestStruct; |
| 13 |
|
| 14 |
typedef struct PointerToOpaque { |
| 15 |
struct Opaque *ptr; |
| 16 |
} PointerToOpaque; |
| 17 |
|
| 18 |
void rust_print_hello_world(void) CF_SWIFT_NAME(rust_print_hello_world()); |
| 19 |
|
| 20 |
void SelfTypeTestStruct_should_exist_ref(const struct SelfTypeTestStruct *self) CF_SWIFT_NAME(SelfTypeTestStruct.should_exist_ref(self:)); |
| 21 |
|
| 22 |
void SelfTypeTestStruct_should_exist_ref_mut(struct SelfTypeTestStruct *self) CF_SWIFT_NAME(SelfTypeTestStruct.should_exist_ref_mut(self:)); |
| 23 |
|
| 24 |
void SelfTypeTestStruct_should_not_exist_box(struct SelfTypeTestStruct *self) CF_SWIFT_NAME(SelfTypeTestStruct.should_not_exist_box(self:)); |
| 25 |
|
| 26 |
struct SelfTypeTestStruct *SelfTypeTestStruct_should_not_exist_return_box(void) CF_SWIFT_NAME(SelfTypeTestStruct.should_not_exist_return_box()); |
| 27 |
|
| 28 |
void SelfTypeTestStruct_should_exist_annotated_self(struct SelfTypeTestStruct self) CF_SWIFT_NAME(SelfTypeTestStruct.should_exist_annotated_self(self:)); |
| 29 |
|
| 30 |
void SelfTypeTestStruct_should_exist_annotated_mut_self(struct SelfTypeTestStruct self) CF_SWIFT_NAME(SelfTypeTestStruct.should_exist_annotated_mut_self(self:)); |
| 31 |
|
| 32 |
void SelfTypeTestStruct_should_exist_annotated_by_name(struct SelfTypeTestStruct self) CF_SWIFT_NAME(SelfTypeTestStruct.should_exist_annotated_by_name(self:)); |
| 33 |
|
| 34 |
void SelfTypeTestStruct_should_exist_annotated_mut_by_name(struct SelfTypeTestStruct self) CF_SWIFT_NAME(SelfTypeTestStruct.should_exist_annotated_mut_by_name(self:)); |
| 35 |
|
| 36 |
void SelfTypeTestStruct_should_exist_unannotated(struct SelfTypeTestStruct self) CF_SWIFT_NAME(SelfTypeTestStruct.should_exist_unannotated(self:)); |
| 37 |
|
| 38 |
void SelfTypeTestStruct_should_exist_mut_unannotated(struct SelfTypeTestStruct self) CF_SWIFT_NAME(SelfTypeTestStruct.should_exist_mut_unannotated(self:)); |
| 39 |
|
| 40 |
void free_function_should_exist_ref(const struct SelfTypeTestStruct *test_struct) CF_SWIFT_NAME(free_function_should_exist_ref(test_struct:)); |
| 41 |
|
| 42 |
void free_function_should_exist_ref_mut(struct SelfTypeTestStruct *test_struct) CF_SWIFT_NAME(free_function_should_exist_ref_mut(test_struct:)); |
| 43 |
|
| 44 |
void unnamed_argument(struct SelfTypeTestStruct*); |
| 45 |
|
| 46 |
void free_function_should_not_exist_box(struct SelfTypeTestStruct *boxed) CF_SWIFT_NAME(free_function_should_not_exist_box(boxed:)); |
| 47 |
|
| 48 |
void free_function_should_exist_annotated_by_name(struct SelfTypeTestStruct test_struct) CF_SWIFT_NAME(free_function_should_exist_annotated_by_name(test_struct:)); |
| 49 |
|
| 50 |
void free_function_should_exist_annotated_mut_by_name(struct SelfTypeTestStruct test_struct) CF_SWIFT_NAME(free_function_should_exist_annotated_mut_by_name(test_struct:)); |
| 51 |
|
| 52 |
struct PointerToOpaque PointerToOpaque_create(uint8_t times) CF_SWIFT_NAME(PointerToOpaque.create(times:)); |
| 53 |
|
| 54 |
void PointerToOpaque_sayHello(struct PointerToOpaque self) CF_SWIFT_NAME(PointerToOpaque.sayHello(self:)); |