File tree 1 file changed +11
-4
lines changed
1 file changed +11
-4
lines changed Original file line number Diff line number Diff line change @@ -253,12 +253,19 @@ namespace ImStb
253
253
#endif
254
254
255
255
// Debug Tools
256
- // Use 'Metrics->Tools->Item Picker' to break into the call-stack of a specific item.
256
+ // Use 'Metrics/Debugger->Tools->Item Picker' to break into the call-stack of a specific item.
257
+ // This will call IM_DEBUG_BREAK() which you may redefine yourself. See https://github.com/scottt/debugbreak for more reference.
257
258
#ifndef IM_DEBUG_BREAK
258
- #if defined(__clang__)
259
- #define IM_DEBUG_BREAK () __builtin_debugtrap()
260
- #elif defined (_MSC_VER)
259
+ #if defined (_MSC_VER)
261
260
#define IM_DEBUG_BREAK () __debugbreak()
261
+ #elif defined(__clang__)
262
+ #define IM_DEBUG_BREAK () __builtin_debugtrap()
263
+ #elif defined(__GNUC__) && (defined(__i386__) || defined(__x86_64__))
264
+ #define IM_DEBUG_BREAK () __asm__ volatile (" int $0x03" )
265
+ #elif defined(__GNUC__) && defined(__thumb__)
266
+ #define IM_DEBUG_BREAK () __asm__ volatile (" .inst 0xde01" )
267
+ #elif defined(__GNUC__) defined(__arm__) && !defined(__thumb__)
268
+ #define IM_DEBUG_BREAK () __asm__ volatile (" .inst 0xe7f001f0" );
262
269
#else
263
270
#define IM_DEBUG_BREAK () IM_ASSERT(0 ) // It is expected that you define IM_DEBUG_BREAK() into something that will break nicely in a debugger!
264
271
#endif
You can’t perform that action at this time.
0 commit comments