summaryrefslogtreecommitdiff
path: root/src/common/cbasetypes.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/common/cbasetypes.h')
-rw-r--r--src/common/cbasetypes.h24
1 files changed, 24 insertions, 0 deletions
diff --git a/src/common/cbasetypes.h b/src/common/cbasetypes.h
index 5ed4a3974..62cb8fe21 100644
--- a/src/common/cbasetypes.h
+++ b/src/common/cbasetypes.h
@@ -198,6 +198,30 @@ typedef uintptr_t uintptr;
//////////////////////////////////////////////////////////////////////////
+// Add a 'sysint' Type which has the width of the platform we're compiled for.
+//////////////////////////////////////////////////////////////////////////
+#if defined(__GNUC__)
+ #if defined(__x86_64__)
+ typedef int64 sysint;
+ typedef uint64 usysint;
+ #else
+ typedef int32 sysint;
+ typedef uint32 usysint;
+ #endif
+#elif defined(_MSC_VER)
+ #if defined(_M_X64)
+ typedef int64 sysint;
+ typedef uint64 usysint;
+ #else
+ typedef int32 sysint;
+ typedef uint32 usysint;
+ #endif
+#else
+ #error Compiler / Platform is unsupported.
+#endif
+
+
+//////////////////////////////////////////////////////////////////////////
// some redefine of function redefines for some Compilers
//////////////////////////////////////////////////////////////////////////
#if defined(_MSC_VER) || defined(__BORLANDC__)