msvcrt: limits.h
Felix Nawothnig
felix.nawothnig at t-online.de
Wed Mar 24 16:04:31 CST 2004
ChangeLog:
- Define all macros described on MSDN in msvcrt/limits.h
Index: include/msvcrt/limits.h
===================================================================
RCS file: /home/wine/wine/include/msvcrt/limits.h,v
retrieving revision 1.1
diff -u -u -r1.1 limits.h
--- include/msvcrt/limits.h 2 Sep 2003 00:58:21 -0000 1.1
+++ include/msvcrt/limits.h 24 Mar 2004 21:24:55 -0000
@@ -1,14 +1,44 @@
#ifndef __WINE_LIMITS_H
#define __WINE_LIMITS_H
-#define INT_MAX 2147483647
-#define INT_MIN (-2147483648)
-#define SHRT_MAX 32767
-#define SHRT_MIN (-32768)
-
#ifdef __cplusplus
extern "C" {
#endif
+
+#define CHAR_BIT 8
+#define MB_LEN_MAX 2
+
+#define SCHAR_MIN (-0x80)
+#define SCHAR_MAX 0x7f
+#define UCHAR_MAX 0xff
+
+#ifdef __CHAR_UNSIGNED__
+# define CHAR_MIN 0
+# define CHAR_MAX UCHAR_MAX
+#else
+# define CHAR_MIN SCHAR_MIN
+# define CHAR_MAX SCHAR_MAX
+#endif
+
+#define SHRT_MIN (-0x8000)
+#define SHRT_MAX 0x7fff
+#define USHRT_MAX 0xffff
+
+#define INT_MIN (-0x80000000)
+#define INT_MAX 0x7fffffff
+#define UINT_MAX 0xffffffff
+
+#define LONG_MIN (-0x80000000)
+#define LONG_MAX 0x7fffffff
+#define ULONG_MAX 0xffffffff
+
+#define _I64_MIN (-0x8000000000000000)
+#define _I64_MAX 0x7fffffffffffffff
+#define _UI64_MAX 0xffffffffffffffff
+
+#define I64_MIN _I64_MIN
+#define I64_MAX _I64_MAX
+#define UI64_MAX _UI64_MAX
#ifdef __cplusplus
}
More information about the wine-patches
mailing list