diff --git a/debugbreak.h b/debugbreak.h index bfb8288..e55aceb 100644 --- a/debugbreak.h +++ b/debugbreak.h @@ -37,8 +37,9 @@ extern "C" { #endif #define DEBUG_BREAK_USE_TRAP_INSTRUCTION 1 -#define DEBUG_BREAK_USE_BULTIN_TRAP 2 +#define DEBUG_BREAK_USE_BUILTIN_TRAP 2 #define DEBUG_BREAK_USE_SIGTRAP 3 +#define DEBUG_BREAK_USE_BUILTIN_DEBUGTRAP 4 #if defined(__i386__) || defined(__x86_64__) #define DEBUG_BREAK_IMPL DEBUG_BREAK_USE_TRAP_INSTRUCTION @@ -91,7 +92,7 @@ __inline__ static void trap_instruction(void) * Same problem and workaround as Thumb mode */ } #elif defined(__aarch64__) && defined(__APPLE__) - #define DEBUG_BREAK_IMPL DEBUG_BREAK_USE_BULTIN_DEBUGTRAP + #define DEBUG_BREAK_IMPL DEBUG_BREAK_USE_BUILTIN_DEBUGTRAP #elif defined(__aarch64__) #define DEBUG_BREAK_IMPL DEBUG_BREAK_USE_TRAP_INSTRUCTION __attribute__((always_inline)) @@ -142,13 +143,13 @@ __inline__ static void debug_break(void) { trap_instruction(); } -#elif DEBUG_BREAK_IMPL == DEBUG_BREAK_USE_BULTIN_DEBUGTRAP +#elif DEBUG_BREAK_IMPL == DEBUG_BREAK_USE_BUILTIN_DEBUGTRAP __attribute__((always_inline)) __inline__ static void debug_break(void) { __builtin_debugtrap(); } -#elif DEBUG_BREAK_IMPL == DEBUG_BREAK_USE_BULTIN_TRAP +#elif DEBUG_BREAK_IMPL == DEBUG_BREAK_USE_BUILTIN_TRAP __attribute__((always_inline)) __inline__ static void debug_break(void) {