]> pd.if.org Git - pdclib/commitdiff
Moved shared defines and typedefs to individual files.
authorsolar <unknown>
Fri, 5 Dec 2003 04:37:27 +0000 (04:37 +0000)
committersolar <unknown>
Fri, 5 Dec 2003 04:37:27 +0000 (04:37 +0000)
16 files changed:
includes/__NULL.h [new file with mode: 0644]
includes/__WCHAR.h [new file with mode: 0644]
includes/__size_t.h [new file with mode: 0644]
includes/__tm.h [new file with mode: 0644]
includes/__wchar_t.h [new file with mode: 0644]
includes/__wint_t.h [new file with mode: 0644]
includes/locale.h
includes/stddef.h
includes/stdio.h
includes/stdlib.h
includes/string.h
includes/time.h
includes/wchar.h
includes/wctype.h
personalities/__personality.h
personalities/stdint.h

diff --git a/includes/__NULL.h b/includes/__NULL.h
new file mode 100644 (file)
index 0000000..7c8cc77
--- /dev/null
@@ -0,0 +1,16 @@
+// ----------------------------------------------------------------------------
+// $Id$
+// ----------------------------------------------------------------------------
+// Public Domain C Library - http://pdclib.sourceforge.net
+// This code is Public Domain. Use, modify, and redistribute at will.
+// ----------------------------------------------------------------------------
+// Definition of NULL shared by locale.h, stddef.h, stdio.h, stdlib.h, 
+// string.h, wchar.h, and time.h
+// ----------------------------------------------------------------------------
+
+#ifndef __NULL_H
+#define __NULL_H __NULL_H
+
+#define NULL 0
+
+#endif // __NULL_H
diff --git a/includes/__WCHAR.h b/includes/__WCHAR.h
new file mode 100644 (file)
index 0000000..cb1a181
--- /dev/null
@@ -0,0 +1,16 @@
+// ----------------------------------------------------------------------------
+// $Id$
+// ----------------------------------------------------------------------------
+// Public Domain C Library - http://pdclib.sourceforge.net
+// This code is Public Domain. Use, modify, and redistribute at will.
+// ----------------------------------------------------------------------------
+// Definition of WCHAR_MIN and WCHAR_MAX, shared by stdint.h and wchar.h
+// ----------------------------------------------------------------------------
+
+#ifndef __WCHAR_H
+#define __WCHAR_H __WCHAR_H
+
+#define WCHAR_MIN // TODO - personality?
+#define WCHAR_MAX // TODO - personality?
+
+#endif // __WCHAR_H
diff --git a/includes/__size_t.h b/includes/__size_t.h
new file mode 100644 (file)
index 0000000..50d7d33
--- /dev/null
@@ -0,0 +1,16 @@
+// ----------------------------------------------------------------------------
+// $Id$
+// ----------------------------------------------------------------------------
+// Public Domain C Library - http://pdclib.sourceforge.net
+// This code is Public Domain. Use, modify, and redistribute at will.
+// ----------------------------------------------------------------------------
+// size_t typedef shared by stddef.h, stdio.h, stdlib.h, string.h, time.h, and
+// wchar.h
+// ----------------------------------------------------------------------------
+
+#ifndef __SIZE_T_H
+#define __SIZE_T_H __SIZE_T_H
+
+typedef size_t; // TODO - personality?
+
+#endif // __SIZE_T_H
diff --git a/includes/__tm.h b/includes/__tm.h
new file mode 100644 (file)
index 0000000..7b6aaaa
--- /dev/null
@@ -0,0 +1,15 @@
+// ----------------------------------------------------------------------------
+// $Id$
+// ----------------------------------------------------------------------------
+// Public Domain C Library - http://pdclib.sourceforge.net
+// This code is Public Domain. Use, modify, and redistribute at will.
+// ----------------------------------------------------------------------------
+// struct tm definition shared by time.h and wchar.h
+// ----------------------------------------------------------------------------
+
+#ifndef __TM_H
+#define __TM_H __TM_H
+
+struct tm; // TODO - personality?
+
+#endif // __TM_H
diff --git a/includes/__wchar_t.h b/includes/__wchar_t.h
new file mode 100644 (file)
index 0000000..029cb2e
--- /dev/null
@@ -0,0 +1,15 @@
+// ----------------------------------------------------------------------------
+// $Id$
+// ----------------------------------------------------------------------------
+// Public Domain C Library - http://pdclib.sourceforge.net
+// This code is Public Domain. Use, modify, and redistribute at will.
+// ----------------------------------------------------------------------------
+// wchar_t typedef shared by stddef.h, stdlib.h, and wchar.h
+// ----------------------------------------------------------------------------
+
+#ifndef __WCHAR_T_H
+#define __WCHAR_T_H __WCHAR_T_H
+
+typedef wchar_t; // TODO - personality?
+
+#endif // __WCHAR_T_H
diff --git a/includes/__wint_t.h b/includes/__wint_t.h
new file mode 100644 (file)
index 0000000..38c8457
--- /dev/null
@@ -0,0 +1,15 @@
+// ----------------------------------------------------------------------------
+// $Id$
+// ----------------------------------------------------------------------------
+// Public Domain C Library - http://pdclib.sourceforge.net
+// This code is Public Domain. Use, modify, and redistribute at will.
+// ----------------------------------------------------------------------------
+// wint_t typedef shared by wchar.h and wctype.h
+// ----------------------------------------------------------------------------
+
+#ifndef __WINT_T_H
+#define __WINT_T_H __WINT_T_H
+
+typedef wint_t; // TODO - personality?
+
+#endif // __WINT_T_H
index 59fd642415194c8c9ec0efc15a5f1c2a6ce69d91..566fa5d40ac8218c9b7fce0b67bb5f2abfc4cf03 100644 (file)
@@ -13,7 +13,7 @@
 // ----------------------------------------------------------------------------
 // DEFINES
 
-#define NULL 0
+#include "__NULL.h"
 
 // Locale categories
 #define LC_COLLATE   1 // affects strcoll() and strxfrm()
index 1c138c7b91324e75b5657d14369a05ae9f3154ac..3c6955b627e6034a7ecdcabe9e4e0ea2b34443c5 100644 (file)
 // ----------------------------------------------------------------------------
 // MACROS
 
-#define NULL  0
+#include "__NULL.h"
+
 #define offsetof( s-type, mbr ) // TODO - personality?
 
 // ----------------------------------------------------------------------------
 // TYPEDEFS
 
-typedef ptrdiff_t; // TODO - personality?
-typedef size_t;    // TODO - personality?
+#include "__size_t.h"
+#include "__wchar_t.h"
 
-#ifndef __cplusplus
-typedef wchar_t;   // TODO - personality?
-#endif // __cplusplus
+typedef ptrdiff_t; // TODO - personality?
 
 #endif // __STDDEF_H
index a4049ebaafdcd498b6669c36d2d44edcfa23d186..e9d323c78e6c1839a493cfdf101a90b98a6b08ce 100644 (file)
@@ -15,6 +15,8 @@
 // ----------------------------------------------------------------------------
 // MACROS
 
+#include "__NULL.h"
+
 #define _IOFBF       // TODO
 #define _IOLBF       // TODO
 #define _IONBF       // TODO
@@ -23,7 +25,6 @@
 #define FILENAME_MAX // TODO
 #define FOPEN_MAX    // TODO
 #define L_tmpnam     // TODO
-#define NULL         0
 #define SEEK_CUR     // TODO
 #define SEEK_END     // TODO
 #define SEEK_SET     // TODO
@@ -36,6 +37,8 @@
 // ----------------------------------------------------------------------------
 // TYPEDEFS
 
+#include "__size_t.h"
+
 typedef FILE;   // TODO - personality?
 typedef fpos_t; // TODO - personality?
 typedef size_t; // TODO - personality?
index fab8a401075cd33247d5d336f56478e3825b8dee..500060ce82f942ff21ee510ecac984390b6c7767 100644 (file)
 // ----------------------------------------------------------------------------
 // MACROS
 
+#include "__NULL.h"
+
 #define EXIT_FAILURE // TODO
 #define EXIT_SUCCESS // TODO
 #define MB_CUR_MAX   // TODO
-#define NULL         0
 #define RAND_MAX     // TODO
 
 // ----------------------------------------------------------------------------
@@ -41,11 +42,8 @@ typedef struct
     long long remainder;
 } lldiv_t;
 
-typedef size_t; // TODO - personality?
-
-#ifndef __cplusplus
-typedef wchar_t; // TODO - personality?
-#endif // __cplusplus
+#include "__size_t.h"
+#include "__wchar_t.h"
 
 // ----------------------------------------------------------------------------
 // FUNCTIONS
index a5e5b21072277c344ab978f4a03a21565b3fefdf..55b94f9a0c47a4b7b4ca10bff878210683479586 100644 (file)
 // ----------------------------------------------------------------------------
 // MACROS
 
-#define NULL 0
+#include "__NULL.h"
 
 // ----------------------------------------------------------------------------
 // TYPEDEFS
 
-typedef size_t; // TODO - personality?
+#include "__size_t.h"
 
 // ----------------------------------------------------------------------------
 // FUNCTIONS
index bc5742c8a5ced53370e20d76829b7e8c785e8904..c527cc31b68003aa1c54a89e55228da5464a25ea 100644 (file)
 // ----------------------------------------------------------------------------
 // MACROS
 
+#include "__NULL.h"
+
 #define CLOCKS_PER_SEC // TODO - personality?
-#define NULL           0
 
 // ----------------------------------------------------------------------------
 // TYPES
 
+#include "__size_t.h"
+#include "__tm.h"
+
 typedef clock_t; // TODO - personality?
-typedef size_t;  // TODO - personality?
 typedef time_t;  // TODO - personality?
-struct tm;       // TODO - personality?
 
 // ----------------------------------------------------------------------------
 // FUNCTIONS
index a86a6fa90110de8b6a6eba303dc7bfb9426f49fb..2af21556aa7a38b2ac5541206002f93bb103a90d 100644 (file)
 // ----------------------------------------------------------------------------
 // MACROS
 
-#define NULL       0
-#define WCHAR_MAX  // TODO - personality?
-#define WCHAR_MIN  // TODO - personality?
+#include "__NULL.h"
+#include "__WCHAR.h"
+
 #define WEOF       // TODO - personality?
 
 // ----------------------------------------------------------------------------
 // TYPEDEFS
 
+#include "__tm.h"
+#include "__size_t.h"
+#include "__wchar_t.h"
+#include "__wint_t.h"
+
 typedef mbstate_t; // TODO - personality?
 typedef size_t;    // TODO - personality?
 typedef wint_t;    // TODO - personality?
-struct tm;         // TODO - personality?
-
-#ifndef __cplusplus
-typedef wchar_t;   // TODO - personality?
-#endif // __cplusplus
 
 // ----------------------------------------------------------------------------
 // FUNCTIONS
index 1c50bfc2810ec21c6e6f94b659456bf0e4ff8936..64012843287c69c7f15ac0f13e200bbd8d81f0a2 100644 (file)
 // ----------------------------------------------------------------------------
 // TYPEDEFS
 
+#include "__wint_t.h"
+
 typedef wctrans_t; // TODO - personality?
 typedef wctype_t;  // TODO - personality?
-typedef wint_t;    // TODO - personality?
 
 // ----------------------------------------------------------------------------
 // FUNCTIONS
index bf2d2a6194a3ce868e9e39de505ebd567f04dcc9..f769b4aa2fb357b08361a2c0dbe8de822ad59c31 100644 (file)
Binary files a/personalities/__personality.h and b/personalities/__personality.h differ
index 4b2a7577de1ec3e071ae49e23eb307cd9fa1409e..d92753a57d607eff2221a26059f8255268d421a2 100644 (file)
@@ -129,8 +129,7 @@ typedef uintmax_t; // TODO
 #define WCHAR_MIN // TODO
 #define WCHAR_MAX // TODO
 
-#define WINT_MIN // TODO
-#define WINT_MAX // TODO
+#include "__WCHAR.h"
 
 #define INTMAX_MIN  // TODO
 #define INTMAX_MAX  // TODO