mirror of https://github.com/CGAL/cgal
static_assert is not affected by NDEBUG
This commit is contained in:
parent
8b228a450f
commit
c04f88368f
|
|
@ -106,24 +106,12 @@ inline bool possibly(Uncertain<bool> c);
|
||||||
# define CGAL_assume_code(CODE) CGAL_assertion_code(CODE)
|
# define CGAL_assume_code(CODE) CGAL_assertion_code(CODE)
|
||||||
#endif // no CGAL_NO_ASSERTIONS
|
#endif // no CGAL_NO_ASSERTIONS
|
||||||
|
|
||||||
# if defined(CGAL_NO_ASSERTIONS)
|
# define CGAL_static_assertion(EX) \
|
||||||
|
|
||||||
# define CGAL_static_assertion(EX) \
|
|
||||||
static_assert(true, "")
|
|
||||||
|
|
||||||
# define CGAL_static_assertion_msg(EX,MSG) \
|
|
||||||
static_assert(true, "")
|
|
||||||
|
|
||||||
# else // no CGAL_NO_ASSERTIONS
|
|
||||||
|
|
||||||
# define CGAL_static_assertion(EX) \
|
|
||||||
static_assert(EX, #EX)
|
static_assert(EX, #EX)
|
||||||
|
|
||||||
# define CGAL_static_assertion_msg(EX,MSG) \
|
# define CGAL_static_assertion_msg(EX,MSG) \
|
||||||
static_assert(EX, MSG)
|
static_assert(EX, MSG)
|
||||||
|
|
||||||
# endif // no CGAL_NO_ASSERTIONS
|
|
||||||
|
|
||||||
#if defined(CGAL_NO_ASSERTIONS) || !defined(CGAL_CHECK_EXACTNESS)
|
#if defined(CGAL_NO_ASSERTIONS) || !defined(CGAL_CHECK_EXACTNESS)
|
||||||
# define CGAL_exactness_assertion(EX) (static_cast<void>(0))
|
# define CGAL_exactness_assertion(EX) (static_cast<void>(0))
|
||||||
# define CGAL_exactness_assertion_msg(EX,MSG) (static_cast<void>(0))
|
# define CGAL_exactness_assertion_msg(EX,MSG) (static_cast<void>(0))
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue