Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/intern
diff options
context:
space:
mode:
authorKester Maddock <Christopher.Maddock.1@uni.massey.ac.nz>2005-01-17 14:02:44 +0300
committerKester Maddock <Christopher.Maddock.1@uni.massey.ac.nz>2005-01-17 14:02:44 +0300
commitb908cfcb07ca28b099953d5a1ddad9a5e1cc85c4 (patch)
tree9bc7db640ffb9895c8f465b0d8a4a5da5595faed /intern
parentc448aa60cae56023b4578936f7202920e3c37c79 (diff)
Use the default windows assert for VisualC
Update Scons
Diffstat (limited to 'intern')
-rw-r--r--intern/moto/SConscript3
-rw-r--r--intern/moto/include/MT_assert.h8
2 files changed, 10 insertions, 1 deletions
diff --git a/intern/moto/SConscript b/intern/moto/SConscript
index 04bd97abc82..b0956c15dd2 100644
--- a/intern/moto/SConscript
+++ b/intern/moto/SConscript
@@ -4,7 +4,8 @@ Import ('library_env')
moto_env = library_env.Copy ()
-source_files = ['intern/MT_CmMatrix4x4.cpp',
+source_files = ['intern/MT_Assert.cpp',
+ 'intern/MT_CmMatrix4x4.cpp',
'intern/MT_Matrix3x3.cpp',
'intern/MT_Matrix4x4.cpp',
'intern/MT_Plane3.cpp',
diff --git a/intern/moto/include/MT_assert.h b/intern/moto/include/MT_assert.h
index dce57b91272..b454461d186 100644
--- a/intern/moto/include/MT_assert.h
+++ b/intern/moto/include/MT_assert.h
@@ -35,11 +35,13 @@
#ifdef MT_NDEBUG
#define MT_assert(predicate) ((void)0)
+#define BREAKPOINT() ((void)0)
#else
#include <signal.h>
#include <stdlib.h>
+#include <assert.h>
// BREAKPOINT() will cause a break into the debugger
#if defined(__i386) && defined(__GNUC__)
@@ -62,6 +64,11 @@
#define BREAKPOINT() \
abort();
#endif
+
+
+#if defined(WIN32) && !defined(__GNUC__)
+#define MT_assert(predicate) assert(predicate)
+#else
// So it can be used from C
#ifdef __cplusplus
@@ -85,6 +92,7 @@ MT_CDECL int MT_QueryAssert(char *file, int line, char *predicate, int *do_asser
BREAKPOINT(); \
} \
}
+#endif /* windows */
#endif /* MT_NDEBUG */