... | ... |
@@ -94,25 +94,31 @@ |
94 | 94 |
# error "LEMON_CUSTOM_ASSERT_HANDLER is not set" |
95 | 95 |
# endif |
96 | 96 |
# define LEMON_ASSERT_HANDLER LEMON_CUSTOM_ASSERT_HANDLER |
97 | 97 |
#elif defined LEMON_DISABLE_ASSERTS |
98 | 98 |
# undef LEMON_ASSERT_HANDLER |
99 | 99 |
#elif defined NDEBUG |
100 | 100 |
# undef LEMON_ASSERT_HANDLER |
101 | 101 |
#else |
102 | 102 |
# define LEMON_ASSERT_HANDLER ::lemon::assert_fail_abort |
103 | 103 |
#endif |
104 | 104 |
|
105 | 105 |
#ifndef LEMON_FUNCTION_NAME |
106 |
# |
|
106 |
# if defined __GNUC__ |
|
107 |
# define LEMON_FUNCTION_NAME (__PRETTY_FUNCTION__) |
|
108 |
# elif defined _MSC_VER |
|
109 |
# define LEMON_FUNCTION_NAME (__FUNCSIG__) |
|
110 |
# else |
|
111 |
# define LEMON_FUNCTION_NAME (__func__) |
|
112 |
# endif |
|
107 | 113 |
#endif |
108 | 114 |
|
109 | 115 |
#ifdef DOXYGEN |
110 | 116 |
|
111 | 117 |
/// \ingroup exceptions |
112 | 118 |
/// |
113 | 119 |
/// \brief Macro for assertion with customizable message |
114 | 120 |
/// |
115 | 121 |
/// Macro for assertion with customizable message. \param exp An |
116 | 122 |
/// expression that must be convertible to \c bool. If it is \c |
117 | 123 |
/// false, then an assertion is raised. The concrete behaviour depends |
118 | 124 |
/// on the settings of the assertion system. \param msg A <tt>const |
0 comments (0 inline)