#ifndef _H_MCUTIL #define _H_MCUTIL // https://fdiv.net/2015/10/08/emulating-defer-c-clang-or-gccblocks #ifndef MCU_ALLOC #define MCU_ALLOC malloc #endif #ifndef MCU_REALLOC #define MCU_REALLOC realloc #endif #ifndef MCU_FREE #define MCU_FREE free #endif #if defined(_MSC_VER) #define MCU_API __declspec(dllexport) #elif defined(__GNUC__) #define MCU_API __attribute__((visibility("default"))) #else #define MCU_API #pragma warning Unknown dynamic link import/export semantics. #endif #endif