2018-10-22 22:44:18 +00:00
|
|
|
#ifndef FUZZER_ASSERT_IMPL_H_
|
|
|
|
#define FUZZER_ASSERT_IMPL_H_
|
|
|
|
|
2021-03-18 17:56:28 +00:00
|
|
|
#if defined(_MSC_VER)
|
|
|
|
extern "C" void __debugbreak();
|
|
|
|
#define __builtin_trap __debugbreak
|
|
|
|
#else // Clang
|
|
|
|
extern "C" void __builtin_trap(void);
|
|
|
|
#endif
|
|
|
|
|
2018-10-22 22:44:18 +00:00
|
|
|
// Declare Debug/Release independed assert macro.
|
|
|
|
#define fuzzer_assert_impl(x) (!!(x) ? static_cast<void>(0) : __builtin_trap())
|
|
|
|
|
|
|
|
#endif // !FUZZER_ASSERT_IMPL_H_
|