Changeset 2409


Ignore:
Timestamp:
Feb 14, 2013, 4:03:33 PM (7 years ago)
Author:
sam
Message:

base: break into the debugger on assertion failure if present.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/lol/base/assert.h

    r2297 r2409  
    2323#else
    2424    std::abort();
     25#endif
     26}
     27
     28/* FIXME: see http://stackoverflow.com/q/3596781/111461 for discussions
     29 * on implementing __debugbreak() on POSIX systems. */
     30static inline void DebugBreak()
     31{
     32#if defined _WIN32
     33    __debugbreak();
    2534#endif
    2635}
     
    107116                                                  (__VA_ARGS__))), \
    108117                     (__VA_ARGS__)); \
     118            DebugBreak(); \
    109119            Abort(); \
    110120        }
Note: See TracChangeset for help on using the changeset viewer.