#ifndef BROLANG_NATIVE_H #define BROLANG_NATIVE_H #include typedef int imported_int; typedef imported_int imported_int_alias; typedef struct Imported_Handle Imported_Handle; typedef void (*Imported_Callback)(int value); typedef int (*Imported_Mapper)(int value); typedef struct Imported_Value { int value; } Imported_Value; typedef union Imported_Union { int value; } Imported_Union; typedef struct Imported_Bitfield { unsigned value : 1; } Imported_Bitfield; typedef struct __attribute__((packed)) Imported_Packed { char first; int second; } Imported_Packed; typedef struct Imported_Flexible { int count; int values[]; } Imported_Flexible; typedef struct Imported_Qualified { const int value; } Imported_Qualified; typedef struct Imported_Overaligned { _Alignas(16) int value; } Imported_Overaligned; typedef struct Imported_Anonymous { struct { int value; }; } Imported_Anonymous; typedef enum Imported_Enum { IMPORTED_ENUM_VALUE, } Imported_Enum; int imported_add(imported_int_alias left, int right); unsigned long imported_scalar(unsigned char value, unsigned long extra); Imported_Handle *imported_handle(void); int imported_read(const Imported_Handle *handle); int imported_string(const char *value); int imported_apply(Imported_Mapper mapper, int value); Imported_Value imported_by_value(Imported_Value value); int imported_volatile(volatile int *value); _Bool imported_bool(_Bool value); extern int imported_global; static inline int imported_inline(int value) { return value; } #ifdef BROLANG_FEATURE int configured_value(int value); #endif #define IMPORTED_MACRO 42 int imported_variadic(int marker, ...); Imported_Bitfield imported_bitfield(Imported_Bitfield value); Imported_Packed imported_packed(Imported_Packed value); Imported_Flexible imported_flexible(Imported_Flexible value); Imported_Qualified imported_qualified(Imported_Qualified value); Imported_Overaligned imported_overaligned(Imported_Overaligned value); Imported_Anonymous imported_anonymous(Imported_Anonymous value); #endif