changeset 10977:6183b030f375

wchar.h: supply WEOF on Irix 5.3 * lib/wchar.in.h (wint_t): Also supply WEOF. * lib/wctype.in.h (wint_t): Likewise. * doc/posix-headers/wchar.texi (wchar.h): Document the bug. * doc/posix-headers/wctype.texi (wctype.h): Likewise. Reported by Tom G. Christensen. Signed-off-by: Eric Blake <ebb9@byu.net>
author Eric Blake <ebb9@byu.net>
date Mon, 29 Dec 2008 09:09:58 -0700
parents ed4dd79550d7
children 1780a93bb27f
files ChangeLog doc/posix-headers/wchar.texi doc/posix-headers/wctype.texi lib/wchar.in.h lib/wctype.in.h
diffstat 5 files changed, 20 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2008-12-29  Eric Blake  <ebb9@byu.net>
+
+	wchar.h: supply WEOF on Irix 5.3
+	* lib/wchar.in.h (wint_t): Also supply WEOF.
+	* lib/wctype.in.h (wint_t): Likewise.
+	* doc/posix-headers/wchar.texi (wchar.h): Document the bug.
+	* doc/posix-headers/wctype.texi (wctype.h): Likewise.
+	Reported by Tom G. Christensen.
+
 2008-12-26  Bruno Haible  <bruno@clisp.org>
 
 	* m4/multiarch.m4 (gl_MULTIARCH): Recognize also the architecture names
@@ -148,9 +157,9 @@
 	* doc/glibc-functions/wmempcpy.texi: Likewise.
 
 2008-12-22  Ingo Weinhold  <ingo_weinhold@gmx.de>  (tiny change)
-            Eric Blake  <ebb9@byu.net>
-            Paolo Bonzini  <bonzini@gnu.org>
-            Bruno Haible  <bruno@clisp.org>
+	    Eric Blake  <ebb9@byu.net>
+	    Paolo Bonzini  <bonzini@gnu.org>
+	    Bruno Haible  <bruno@clisp.org>
 
 	Make c-stack work on Haiku.
 	* lib/c-stack.c (SA_ONSTACK): Define fallback.
--- a/doc/posix-headers/wchar.texi
+++ b/doc/posix-headers/wchar.texi
@@ -14,7 +14,7 @@
 This header file is not self-contained on some platforms:
 OSF/1 with Desktop Toolkit C, BSD/OS 4.0.1.
 @item
-The type @code{wint_t} is missing on some platforms:
+The type @code{wint_t} and macro @code{WEOF} are missing on some platforms:
 IRIX 5.3.
 @end itemize
 
--- a/doc/posix-headers/wctype.texi
+++ b/doc/posix-headers/wctype.texi
@@ -14,7 +14,7 @@
 This header file is not self-contained on some platforms:
 Solaris 2.5, OSF/1 with Desktop Toolkit C, BSD/OS 4.0.1.
 @item
-The type @code{wint_t} is missing on some platforms:
+The type @code{wint_t} and macro @code{WEOF} are missing on some platforms:
 IRIX 5.3.
 @item
 The functions @code{isw*} are missing on some platforms:
--- a/lib/wchar.in.h
+++ b/lib/wchar.in.h
@@ -68,6 +68,9 @@
 /* Define wint_t.  (Also done in wctype.in.h.)  */
 #if !@HAVE_WINT_T@ && !defined wint_t
 # define wint_t int
+# ifndef WEOF
+#  define WEOF -1
+# endif
 #endif
 
 
--- a/lib/wctype.in.h
+++ b/lib/wctype.in.h
@@ -57,6 +57,9 @@
 /* Define wint_t.  (Also done in wchar.in.h.)  */
 #if !@HAVE_WINT_T@ && !defined wint_t
 # define wint_t int
+# ifndef WEOF
+#  define WEOF -1
+# endif
 #endif
 
 /* FreeBSD 4.4 to 4.11 has <wctype.h> but lacks the functions.