Further fixes for Assert
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
This commit is contained in:
parent
07f215a4fa
commit
2d4cc2cd80
|
@ -1,5 +1,3 @@
|
|||
#ifndef ARBUTILS_ASSERT_HPP
|
||||
#define ARBUTILS_ASSERT_HPP
|
||||
#include <sstream>
|
||||
#include <stdexcept>
|
||||
#include <string.h>
|
||||
|
@ -15,12 +13,10 @@
|
|||
ss << #expr << "\""; \
|
||||
throw std::logic_error(ss.str()); \
|
||||
} \
|
||||
}
|
||||
};
|
||||
#else
|
||||
// Assert is empty if NO_ASSERT is defined.
|
||||
#define Assert(expr)
|
||||
#endif
|
||||
|
||||
#define AssertNotNull(value) Assert(value != nullptr)
|
||||
|
||||
#endif
|
Loading…
Reference in New Issue