]> pd.if.org Git - pdclib/blobdiff - includes/wctype.h
PDCLib includes with quotes, not <>.
[pdclib] / includes / wctype.h
index 3b3e211eb5fe1d78b9b36dcc1690b09255a243bc..9a71e16af930703ad7673611f4a969d8761b1de6 100644 (file)
@@ -1,57 +1,65 @@
-/* ----------------------------------------------------------------------------
- * $Id$
- * ----------------------------------------------------------------------------
- * Public Domain C Library - http://pdclib.sourceforge.net
- * This code is Public Domain. Use, modify, and redistribute at will.
- * ----------------------------------------------------------------------------
- * Wide character classification and mapping utilities
- * --------------------------------------------------------------------------*/
-
-#ifndef _WCTYPE_H
-#define _WCTYPE_H _WCTYPE_H
-
-#ifndef _NULL
-#define _NULL _NULL
-#include "__intern.h"
-#endif /* _NULL */
-
-/* TODO: Documentation */
-
-/* ----------------------------------------------------------------------------
- * TYPEDEFS
- * --------------------------------------------------------------------------*/
-
-#ifndef _WINT_T
-#define _WINT_T _WINT_T
-typedef __wint_t wint_t
-#endif /* _WINT_T */
-
-typedef wctrans_t; /* TODO - to __intern.h / __personality.h? */
-typedef wctype_t;  /* TODO - to __intern.h / __personality.h? */
-
-/* ----------------------------------------------------------------------------
- * FUNCTIONS
- * --------------------------------------------------------------------------*/
-
-int iswalnum( wint_t c );
-int iswalpha( wint_t c );
-int iswblank( wint_t c );
-int iswcntrl( wint_t c );
-int iswctype( wint_t c, wctype_t category );
-int iswdigit( wint_t c );
-int iswgraph( wint_t c );
-int iswlower( wint_t c );
-int iswprint( wint_t c );
-int iswpunct( wint_t c );
-int iswspace( wint_t c );
-int iswupper( wint_t c );
-int iswxdigit( wint_t c );
-
-wint_t towctrans( wint_t c, wctrans_t category );
-wint_t towlower( wint_t c );
-wint_t towupper( wint_t c );
-
-wctrans_t wctrans( const char * property );
-wctype_t wctype( const char * property );
-
-#endif /* _WCTYPE_H */
+/* Wide character classification and mapping utilities <wctype.h>
+
+   This file is part of the Public Domain C Library (PDCLib).
+   Permission is granted to use, modify, and / or redistribute at will.
+*/
+
+#ifndef _PDCLIB_WCTYPE_H
+#define _PDCLIB_WCTYPE_H _PDCLIB_WCTYPE_H
+#include "_PDCLIB_int.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#ifndef _PDCLIB_WINT_T_DEFINED
+#define _PDCLIB_WINT_T_DEFINED _PDCLIB_WINT_T_DEFINED
+typedef _PDCLIB_wint_t wint_t;
+#endif
+
+#ifndef _PDCLIB_WEOF_DEFINED
+#define _PDCLIB_WEOF_DEFINED _PDCLIB_WEOF_DEFINED
+#define WEOF _PDCLIB_WEOF
+#endif
+
+/* Scalar type representing locale-specific character mappings */
+typedef int wctrans_t;
+
+/* Scalar type representing locale-specific character classifications */
+typedef int wctype_t;
+
+/* Character classification functions */
+
+int iswalnum( wint_t _Wc );
+int iswalpha( wint_t _Wc );
+int iswblank( wint_t _Wc );
+int iswcntrl( wint_t _Wc );
+int iswdigit( wint_t _Wc );
+int iswgraph( wint_t _Wc );
+int iswlower( wint_t _Wc );
+int iswprint( wint_t _Wc );
+int iswpunct( wint_t _Wc );
+int iswspace( wint_t _Wc );
+int iswupper( wint_t _Wc );
+int iswxdigit( wint_t _Wc );
+
+/* Extensible character classification functions */
+
+int iswctype( wint_t _Wc, wctype_t _Desc );
+wctype_t wctype( const char * _Property );
+
+/* Wide character case mapping utilities */
+
+wint_t towlower( wint_t _Wc );
+wint_t towupper( wint_t _Wc );
+
+/* Extensible wide character case mapping functions */
+
+wint_t towctrans( wint_t _Wc, wctrans_t _Desc );
+wctrans_t wctrans( const char * _Property );
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif