]> Shamusworld >> Repos - ttedit/blobdiff - src/types.h
Converted from Qt4 to Qt5.
[ttedit] / src / types.h
index 7f589aa434847d901d05acb8407f463a97ce1cfa..0fc13b5e9f768c68af4f83ca369a01ed3f60e50d 100755 (executable)
@@ -1,33 +1,30 @@
-//\r
-// Basic types for platform independent code\r
-//\r
-\r
-#ifndef __TYPES_H__\r
-#define __TYPES_H__\r
-\r
-// This is only good on certain intel 32-bit platforms...\r
-// You may need to tweak to suit your specific platform.\r
-\r
-typedef unsigned char          uint8;\r
-typedef signed char                    int8;\r
-typedef unsigned short         uint16;\r
-typedef signed short           int16;\r
-typedef unsigned                       uint32;\r
-typedef signed                         int32;\r
-//typedef unsigned long long   uint64;\r
-//typedef signed long long     int64;\r
-\r
-//typedef signed char                  SBYTE;\r
-//typedef signed short int     SWORD;\r
-//typedef signed long int              SDWORD;\r
-\r
-/*#ifndef _WINDOWS_\r
-#define NULL   0\r
-// This is for non-compliant compilers that don't follow proper scoping rules (and suck). ;-)\r
-#define for if(false);else for\r
-#endif*/\r
-#ifndef NULL\r
-#define NULL    0\r
-#endif\r
-\r
-#endif // __TYPES_H__\r
+//
+// Basic types for platform independent code
+//
+
+#ifndef __TYPES_H__
+#define __TYPES_H__
+
+// This should be portable, since it's part of the C99 standard...!
+
+#include <stdint.h>
+
+typedef uint8_t                uint8;
+typedef int8_t         int8;
+typedef uint16_t       uint16;
+typedef int16_t                int16;
+typedef uint32_t       uint32;
+typedef int32_t                int32;
+typedef uint64_t       uint64;
+typedef int64_t                int64;
+
+/*#ifndef _WINDOWS_
+#define NULL   0
+// This is for non-compliant compilers that don't follow proper scoping rules (and suck). ;-)
+#define for if(false);else for
+#endif*/
+#ifndef NULL
+#define NULL    0
+#endif
+
+#endif // __TYPES_H__