diff --git a/library/PolyVoxCore/include/PolyVoxCore/Impl/ErrorHandling.h b/library/PolyVoxCore/include/PolyVoxCore/Impl/ErrorHandling.h index b99f0278..15570bb9 100644 --- a/library/PolyVoxCore/include/PolyVoxCore/Impl/ErrorHandling.h +++ b/library/PolyVoxCore/include/PolyVoxCore/Impl/ErrorHandling.h @@ -24,11 +24,17 @@ freely, subject to the following restrictions: #ifndef __PolyVox_ErrorHandling_H__ #define __PolyVox_ErrorHandling_H__ -#include +#include //For std::exit +#include //For std::cerr #define POLYVOX_ASSERTS_ENABLED -#define POLYVOX_HALT() __debugbreak() +#if defined(_MSC_VER) + #define POLYVOX_HALT() __debugbreak() +#else + #define POLYVOX_HALT() std::exit(EXIT_FAILURE) +#endif + #define POLYVOX_UNUSED(x) do { (void)sizeof(x); } while(0) /*