#pragma once #if !defined(__cplusplus) typedef enum bool { false, true } bool; #if !defined(CONST_CAST) #define CONST_CAST(t) (t) #endif #define STATIC_CAST(t) (t) #define REINTERPRET_CAST(t) (t) #define INT_TO_ENUM_CAST(e) /* nothing */ #define FUNCTION_POINTER_CAST(t) (t) #else #if !defined(CONST_CAST) #define CONST_CAST(t) const_cast #endif #define STATIC_CAST(t) static_cast #define INT_TO_ENUM_CAST(e) static_cast #define REINTERPRET_CAST(t) reinterpret_cast #define FUNCTION_POINTER_CAST(t) reinterpret_cast #endif