about summary refs log tree commit diff
path: root/stdlib
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>1999-10-09 21:56:43 +0000
committerUlrich Drepper <drepper@redhat.com>1999-10-09 21:56:43 +0000
commitc1422e5b7cdb4400f934c91bcefa3a1a96d789fb (patch)
tree7f8981b86c4ce4b5bb899f690eeb03d6645826a5 /stdlib
parenta4a1492eb94de4f5c5ec84a5898e994fca5f317b (diff)
downloadglibc-c1422e5b7cdb4400f934c91bcefa3a1a96d789fb.tar.gz
glibc-c1422e5b7cdb4400f934c91bcefa3a1a96d789fb.tar.xz
glibc-c1422e5b7cdb4400f934c91bcefa3a1a96d789fb.zip
Update.
	Patch by khendricks@ivey.uwo.ca [libc/1382].
Diffstat (limited to 'stdlib')
-rw-r--r--stdlib/alloca.h4
-rw-r--r--stdlib/fmtmsg.h8
-rw-r--r--stdlib/monetary.h10
-rw-r--r--stdlib/stdlib.h415
-rw-r--r--stdlib/ucontext.h12
5 files changed, 224 insertions, 225 deletions
diff --git a/stdlib/alloca.h b/stdlib/alloca.h
index 741eca7431..374f6bb9f6 100644
--- a/stdlib/alloca.h
+++ b/stdlib/alloca.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 1992, 1996, 1997, 1998 Free Software Foundation, Inc.
+/* Copyright (C) 1992, 1996, 1997, 1998, 1999 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -30,7 +30,7 @@ __BEGIN_DECLS
 #undef	alloca
 
 /* Allocate a block that will be freed when the calling function exits.  */
-extern __ptr_t alloca __P ((size_t __size));
+extern void *alloca (size_t __size) __THROW;
 
 #ifdef	__GNUC__
 # define alloca(size)	__builtin_alloca (size)
diff --git a/stdlib/fmtmsg.h b/stdlib/fmtmsg.h
index 56139b9a25..ae166840cd 100644
--- a/stdlib/fmtmsg.h
+++ b/stdlib/fmtmsg.h
@@ -92,13 +92,13 @@ enum
 
 /* Print message with given CLASSIFICATION, LABEL, SEVERITY, TEXT, ACTION
    and TAG to console or standard error.  */
-extern int fmtmsg __P ((long int __classification, __const char *__label,
-			int __severity, __const char *__text,
-			__const char *__action, __const char *__tag));
+extern int fmtmsg (long int __classification, __const char *__label,
+		   int __severity, __const char *__text,
+		   __const char *__action, __const char *__tag) __THROW;
 
 #ifdef __USE_SVID
 /* Add or remove severity level.  */
-extern int addseverity __P ((int __severity, __const char *__string));
+extern int addseverity (int __severity, __const char *__string) __THROW;
 #endif
 
 __END_DECLS
diff --git a/stdlib/monetary.h b/stdlib/monetary.h
index de288a208b..e665f07e8f 100644
--- a/stdlib/monetary.h
+++ b/stdlib/monetary.h
@@ -36,16 +36,16 @@ typedef __ssize_t ssize_t;
 __BEGIN_DECLS
 
 /* Formatting a monetary value according to the current locale.  */
-extern ssize_t strfmon __P ((char *__restrict __s, size_t __maxsize,
-			     __const char *__restrict __format, ...));
+extern ssize_t strfmon (char *__restrict __s, size_t __maxsize,
+			__const char *__restrict __format, ...) __THROW;
 
 #ifdef __USE_GNU
 # include <xlocale.h>
 
 /* Formatting a monetary value according to the current locale.  */
-extern ssize_t __strfmon_l __P ((char *__restrict __s, size_t __maxsize,
-				 __locale_t loc,
-				 __const char *__restrict __format, ...));
+extern ssize_t __strfmon_l (char *__restrict __s, size_t __maxsize,
+			    __locale_t loc,
+			    __const char *__restrict __format, ...) __THROW;
 #endif
 
 __END_DECLS
diff --git a/stdlib/stdlib.h b/stdlib/stdlib.h
index 70a975edf9..30a10831e1 100644
--- a/stdlib/stdlib.h
+++ b/stdlib/stdlib.h
@@ -77,52 +77,52 @@ __extension__ typedef struct
 
 /* Maximum length of a multibyte character in the current locale.  */
 #define	MB_CUR_MAX	(__ctype_get_mb_cur_max ())
-extern size_t __ctype_get_mb_cur_max __P ((void));
+extern size_t __ctype_get_mb_cur_max (void) __THROW;
 
 
 /* Convert a string to a floating-point number.  */
-extern double atof __P ((__const char *__nptr));
+extern double atof (__const char *__nptr) __THROW;
 /* Convert a string to an integer.  */
-extern int atoi __P ((__const char *__nptr));
+extern int atoi (__const char *__nptr) __THROW;
 /* Convert a string to a long integer.  */
-extern long int atol __P ((__const char *__nptr));
+extern long int atol (__const char *__nptr) __THROW;
 
 #if defined __USE_ISOC9X || (defined __GNUC__ && defined __USE_MISC)
 /* These functions will part of the standard C library in ISO C 9X.  */
-__extension__ extern long long int atoll __P ((__const char *__nptr));
+__extension__ extern long long int atoll (__const char *__nptr) __THROW;
 #endif
 
 /* Convert a string to a floating-point number.  */
-extern double strtod __P ((__const char *__restrict __nptr,
-			   char **__restrict __endptr));
+extern double strtod (__const char *__restrict __nptr,
+		      char **__restrict __endptr) __THROW;
 
 #ifdef	__USE_ISOC9X
 /* Likewise for `float' and `long double' sizes of floating-point numbers.  */
-extern float strtof __P ((__const char *__restrict __nptr,
-			  char **__restrict __endptr));
+extern float strtof (__const char *__restrict __nptr,
+		     char **__restrict __endptr) __THROW;
 
-extern __long_double_t strtold __P ((__const char *__restrict __nptr,
-				     char **__restrict __endptr));
+extern long double strtold (__const char *__restrict __nptr,
+			    char **__restrict __endptr) __THROW;
 #endif
 
 /* Convert a string to a long integer.  */
-extern long int strtol __P ((__const char *__restrict __nptr,
-			     char **__restrict __endptr, int __base));
+extern long int strtol (__const char *__restrict __nptr,
+			char **__restrict __endptr, int __base) __THROW;
 /* Convert a string to an unsigned long integer.  */
-extern unsigned long int strtoul __P ((__const char *__restrict __nptr,
-				       char **__restrict __endptr,
-				       int __base));
+extern unsigned long int strtoul (__const char *__restrict __nptr,
+				  char **__restrict __endptr, int __base)
+     __THROW;
 
 #if defined __GNUC__ && defined __USE_BSD
 /* Convert a string to a quadword integer.  */
 __extension__
-extern long long int strtoq __P ((__const char *__restrict __nptr,
-				  char **__restrict __endptr, int __base));
+extern long long int strtoq (__const char *__restrict __nptr,
+			     char **__restrict __endptr, int __base) __THROW;
 /* Convert a string to an unsigned quadword integer.  */
 __extension__
-extern unsigned long long int strtouq __P ((__const char *__restrict __nptr,
-					    char **__restrict __endptr,
-					    int __base));
+extern unsigned long long int strtouq (__const char *__restrict __nptr,
+				       char **__restrict __endptr, int __base)
+     __THROW;
 #endif /* GCC and use BSD.  */
 
 #if defined __USE_ISOC9X || (defined __GNUC__ && defined __USE_MISC)
@@ -130,13 +130,13 @@ extern unsigned long long int strtouq __P ((__const char *__restrict __nptr,
 
 /* Convert a string to a quadword integer.  */
 __extension__
-extern long long int strtoll __P ((__const char *__restrict __nptr,
-				   char **__restrict __endptr, int __base));
+extern long long int strtoll (__const char *__restrict __nptr,
+			      char **__restrict __endptr, int __base) __THROW;
 /* Convert a string to an unsigned quadword integer.  */
 __extension__
-extern unsigned long long int strtoull __P ((__const char *__restrict __nptr,
-					     char **__restrict __endptr,
-					     int __base));
+extern unsigned long long int strtoull (__const char *__restrict __nptr,
+					char **__restrict __endptr, int __base)
+     __THROW;
 #endif /* ISO C 9X or GCC and use MISC.  */
 
 
@@ -158,79 +158,77 @@ extern unsigned long long int strtoull __P ((__const char *__restrict __nptr,
 
 /* Special versions of the functions above which take the locale to
    use as an additional parameter.  */
-extern long int __strtol_l __P ((__const char *__restrict __nptr,
-				 char **__restrict __endptr, int __base,
-				 __locale_t __loc));
+extern long int __strtol_l (__const char *__restrict __nptr,
+			    char **__restrict __endptr, int __base,
+			    __locale_t __loc) __THROW;
 
-extern unsigned long int __strtoul_l __P ((__const char *__restrict __nptr,
-					   char **__restrict __endptr,
-					   int __base, __locale_t __loc));
+extern unsigned long int __strtoul_l (__const char *__restrict __nptr,
+				      char **__restrict __endptr,
+				      int __base, __locale_t __loc) __THROW;
 
 __extension__
-extern long long int __strtoll_l __P ((__const char *__restrict __nptr,
-				       char **__restrict __endptr, int __base,
-				       __locale_t __loc));
+extern long long int __strtoll_l (__const char *__restrict __nptr,
+				  char **__restrict __endptr, int __base,
+				  __locale_t __loc) __THROW;
 
 __extension__
-extern unsigned long long int __strtoull_l __P ((__const char *__restrict
-						 __nptr,
-						 char **__restrict __endptr,
-						 int __base,
-						 __locale_t __loc));
+extern unsigned long long int __strtoull_l (__const char *__restrict __nptr,
+					    char **__restrict __endptr,
+					    int __base, __locale_t __loc)
+     __THROW;
 
-extern double __strtod_l __P ((__const char *__restrict __nptr,
-			       char **__restrict __endptr, __locale_t __loc));
+extern double __strtod_l (__const char *__restrict __nptr,
+			  char **__restrict __endptr, __locale_t __loc)
+     __THROW;
 
-extern float __strtof_l __P ((__const char *__restrict __nptr,
-			      char **__restrict __endptr, __locale_t __loc));
+extern float __strtof_l (__const char *__restrict __nptr,
+			 char **__restrict __endptr, __locale_t __loc) __THROW;
 
-extern __long_double_t __strtold_l __P ((__const char *__restrict __nptr,
-					 char **__restrict __endptr,
-					 __locale_t __loc));
+extern long double __strtold_l (__const char *__restrict __nptr,
+				char **__restrict __endptr,
+				__locale_t __loc) __THROW;
 #endif /* GNU */
 
 
 /* The internal entry points for `strtoX' take an extra flag argument
    saying whether or not to parse locale-dependent number grouping.  */
 
-extern double __strtod_internal __P ((__const char *__restrict __nptr,
-				      char **__restrict __endptr,
-				      int __group));
-extern float __strtof_internal __P ((__const char *__restrict __nptr,
-				     char **__restrict __endptr, int __group));
-extern __long_double_t __strtold_internal __P ((__const char *
-						__restrict __nptr,
-						char **__restrict __endptr,
-						int __group));
+extern double __strtod_internal (__const char *__restrict __nptr,
+				 char **__restrict __endptr, int __group)
+     __THROW;
+extern float __strtof_internal (__const char *__restrict __nptr,
+				char **__restrict __endptr, int __group)
+     __THROW;
+extern long double __strtold_internal (__const char *__restrict __nptr,
+				       char **__restrict __endptr,
+				       int __group) __THROW;
 #ifndef __strtol_internal_defined
-extern long int __strtol_internal __P ((__const char *__restrict __nptr,
-					char **__restrict __endptr,
-					int __base, int __group));
+extern long int __strtol_internal (__const char *__restrict __nptr,
+				   char **__restrict __endptr,
+				   int __base, int __group) __THROW;
 # define __strtol_internal_defined	1
 #endif
 #ifndef __strtoul_internal_defined
-extern unsigned long int __strtoul_internal __P ((__const char *
-						  __restrict __nptr,
-						  char **__restrict __endptr,
-						  int __base, int __group));
+extern unsigned long int __strtoul_internal (__const char *__restrict __nptr,
+					     char **__restrict __endptr,
+					     int __base, int __group) __THROW;
 # define __strtoul_internal_defined	1
 #endif
 #if defined __GNUC__ || defined __USE_ISOC9X
 # ifndef __strtoll_internal_defined
 __extension__
-extern long long int __strtoll_internal __P ((__const char *__restrict __nptr,
-					      char **__restrict __endptr,
-					      int __base, int __group));
+extern long long int __strtoll_internal (__const char *__restrict __nptr,
+					 char **__restrict __endptr,
+					 int __base, int __group) __THROW;
 #  define __strtoll_internal_defined	1
 # endif
 # ifndef __strtoull_internal_defined
 __extension__
-extern unsigned long long int __strtoull_internal __P ((__const char *
-							__restrict __nptr,
-							char **
-							__restrict __endptr,
-							int __base,
-							int __group));
+extern unsigned long long int __strtoull_internal (__const char *
+						   __restrict __nptr,
+						   char **__restrict __endptr,
+						   int __base, int __group)
+     __THROW;
 #  define __strtoull_internal_defined	1
 # endif
 #endif /* GCC */
@@ -263,7 +261,7 @@ strtof (__const char *__restrict __nptr, char **__restrict __endptr) __THROW
 {
   return __strtof_internal (__nptr, __endptr, 0);
 }
-extern __inline __long_double_t
+extern __inline long double
 strtold (__const char *__restrict __nptr, char **__restrict __endptr) __THROW
 {
   return __strtold_internal (__nptr, __endptr, 0);
@@ -330,10 +328,10 @@ atoll (__const char *__nptr) __THROW
 /* Convert N to base 64 using the digits "./0-9A-Za-z", least-significant
    digit first.  Returns a pointer to static storage overwritten by the
    next call.  */
-extern char *l64a __P ((long int __n));
+extern char *l64a (long int __n) __THROW;
 
 /* Read a number from a string S in base 64 as above.  */
-extern long int a64l __P ((__const char *__s));
+extern long int a64l (__const char *__s) __THROW;
 
 
 # include <sys/types.h>	/* we need int32_t... */
@@ -343,21 +341,21 @@ extern long int a64l __P ((__const char *__s));
    The `rand' and `srand' functions are required by the ANSI standard.
    We provide both interfaces to the same random number generator.  */
 /* Return a random long integer between 0 and RAND_MAX inclusive.  */
-extern int32_t random __P ((void));
+extern int32_t random (void) __THROW;
 
 /* Seed the random number generator with the given number.  */
-extern void srandom __P ((unsigned int __seed));
+extern void srandom (unsigned int __seed) __THROW;
 
 /* Initialize the random number generator to use state buffer STATEBUF,
    of length STATELEN, and seed it with SEED.  Optimal lengths are 8, 16,
    32, 64, 128 and 256, the bigger the better; values less than 8 will
    cause an error and values greater than 256 will be rounded down.  */
-extern __ptr_t initstate __P ((unsigned int __seed, __ptr_t __statebuf,
-			       size_t __statelen));
+extern void *initstate (unsigned int __seed, void *__statebuf,
+			size_t __statelen) __THROW;
 
 /* Switch the random number generator to state buffer STATEBUF,
    which should have been previously initialized by `initstate'.  */
-extern __ptr_t setstate __P ((__ptr_t __statebuf));
+extern void *setstate (void *__statebuf) __THROW;
 
 
 # ifdef __USE_MISC
@@ -376,30 +374,29 @@ struct random_data
     int32_t *end_ptr;		/* Pointer behind state table.  */
   };
 
-extern int random_r __P ((struct random_data *__restrict __buf,
-			  int32_t *__restrict __result));
+extern int random_r (struct random_data *__restrict __buf,
+		     int32_t *__restrict __result) __THROW;
 
-extern int srandom_r __P ((unsigned int __seed, struct random_data *__buf));
+extern int srandom_r (unsigned int __seed, struct random_data *__buf) __THROW;
 
-extern int initstate_r __P ((unsigned int __seed,
-			     __ptr_t __restrict __statebuf,
-			     size_t __statelen,
-			     struct random_data *__restrict __buf));
+extern int initstate_r (unsigned int __seed, void *__restrict __statebuf,
+			size_t __statelen,
+			struct random_data *__restrict __buf) __THROW;
 
-extern int setstate_r __P ((__ptr_t __restrict __statebuf,
-			    struct random_data *__restrict __buf));
+extern int setstate_r (void *__restrict __statebuf,
+		       struct random_data *__restrict __buf) __THROW;
 # endif	/* Use misc.  */
 #endif	/* Use SVID || extended X/Open.  */
 
 
 /* Return a random integer between 0 and RAND_MAX inclusive.  */
-extern int rand __P ((void));
+extern int rand (void) __THROW;
 /* Seed the random number generator with the given number.  */
-extern void srand __P ((unsigned int __seed));
+extern void srand (unsigned int __seed) __THROW;
 
 #ifdef __USE_POSIX
 /* Reentrant interface according to POSIX.1.  */
-extern int rand_r __P ((unsigned int *__seed));
+extern int rand_r (unsigned int *__seed) __THROW;
 #endif
 
 
@@ -407,21 +404,21 @@ extern int rand_r __P ((unsigned int *__seed));
 /* System V style 48-bit random number generator functions.  */
 
 /* Return non-negative, double-precision floating-point value in [0.0,1.0).  */
-extern double drand48 __P ((void));
-extern double erand48 __P ((unsigned short int __xsubi[3]));
+extern double drand48 (void) __THROW;
+extern double erand48 (unsigned short int __xsubi[3]) __THROW;
 
 /* Return non-negative, long integer in [0,2^31).  */
-extern long int lrand48 __P ((void));
-extern long int nrand48 __P ((unsigned short int __xsubi[3]));
+extern long int lrand48 (void) __THROW;
+extern long int nrand48 (unsigned short int __xsubi[3]) __THROW;
 
 /* Return signed, long integers in [-2^31,2^31).  */
-extern long int mrand48 __P ((void));
-extern long int jrand48 __P ((unsigned short int __xsubi[3]));
+extern long int mrand48 (void) __THROW;
+extern long int jrand48 (unsigned short int __xsubi[3]) __THROW;
 
 /* Seed random number generator.  */
-extern void srand48 __P ((long int __seedval));
-extern unsigned short int *seed48 __P ((unsigned short int __seed16v[3]));
-extern void lcong48 __P ((unsigned short int __param[7]));
+extern void srand48 (long int __seedval) __THROW;
+extern unsigned short int *seed48 (unsigned short int __seed16v[3]) __THROW;
+extern void lcong48 (unsigned short int __param[7]) __THROW;
 
 /* Data structure for communication with thread safe versions.  */
 struct drand48_data
@@ -435,34 +432,35 @@ struct drand48_data
 
 # ifdef __USE_MISC
 /* Return non-negative, double-precision floating-point value in [0.0,1.0).  */
-extern int drand48_r __P ((struct drand48_data *__restrict __buffer,
-			   double *__restrict __result));
-extern int erand48_r __P ((unsigned short int __xsubi[3],
-			   struct drand48_data *__restrict __buffer,
-			   double *__restrict __result));
+extern int drand48_r (struct drand48_data *__restrict __buffer,
+		      double *__restrict __result) __THROW;
+extern int erand48_r (unsigned short int __xsubi[3],
+		      struct drand48_data *__restrict __buffer,
+		      double *__restrict __result) __THROW;
 
 /* Return non-negative, long integer in [0,2^31).  */
-extern int lrand48_r __P ((struct drand48_data *__restrict __buffer,
-			   long int *__restrict __result));
-extern int nrand48_r __P ((unsigned short int __xsubi[3],
-			   struct drand48_data *__restrict __buffer,
-			   long int *__restrict __result));
+extern int lrand48_r (struct drand48_data *__restrict __buffer,
+		      long int *__restrict __result) __THROW;
+extern int nrand48_r (unsigned short int __xsubi[3],
+		      struct drand48_data *__restrict __buffer,
+		      long int *__restrict __result) __THROW;
 
 /* Return signed, long integers in [-2^31,2^31).  */
-extern int mrand48_r __P ((struct drand48_data *__restrict __buffer,
-			   long int *__restrict __result));
-extern int jrand48_r __P ((unsigned short int __xsubi[3],
-			   struct drand48_data *__restrict __buffer,
-			   long int *__restrict __result));
+extern int mrand48_r (struct drand48_data *__restrict __buffer,
+		      long int *__restrict __result) __THROW;
+extern int jrand48_r (unsigned short int __xsubi[3],
+		      struct drand48_data *__restrict __buffer,
+		      long int *__restrict __result) __THROW;
 
 /* Seed random number generator.  */
-extern int srand48_r __P ((long int __seedval, struct drand48_data *__buffer));
+extern int srand48_r (long int __seedval, struct drand48_data *__buffer)
+     __THROW;
 
-extern int seed48_r __P ((unsigned short int __seed16v[3],
-			  struct drand48_data *__buffer));
+extern int seed48_r (unsigned short int __seed16v[3],
+		     struct drand48_data *__buffer) __THROW;
 
-extern int lcong48_r __P ((unsigned short int __param[7],
-			   struct drand48_data *__buffer));
+extern int lcong48_r (unsigned short int __param[7],
+		      struct drand48_data *__buffer) __THROW;
 # endif	/* Use misc.  */
 #endif	/* Use SVID or X/Open.  */
 
@@ -471,21 +469,21 @@ extern int lcong48_r __P ((unsigned short int __param[7],
 #ifndef __malloc_and_calloc_defined
 #define __malloc_and_calloc_defined
 /* Allocate SIZE bytes of memory.  */
-extern __ptr_t malloc __P ((size_t __size));
+extern void *malloc (size_t __size) __THROW;
 /* Allocate NMEMB elements of SIZE bytes each, all initialized to 0.  */
-extern __ptr_t calloc __P ((size_t __nmemb, size_t __size));
+extern void *calloc (size_t __nmemb, size_t __size) __THROW;
 #endif
 
 #ifndef __need_malloc_and_calloc
 /* Re-allocate the previously allocated block
-   in __ptr_t, making the new block SIZE bytes long.  */
-extern __ptr_t realloc __P ((__ptr_t __ptr, size_t __size));
+   in PTR, making the new block SIZE bytes long.  */
+extern void *realloc (void *__ptr, size_t __size) __THROW;
 /* Free a block allocated by `malloc', `realloc' or `calloc'.  */
-extern void free __P ((__ptr_t __ptr));
+extern void free (void *__ptr) __THROW;
 
 #ifdef	__USE_MISC
 /* Free a block.  An alias for `free'.	(Sun Unices).  */
-extern void cfree __P ((__ptr_t __ptr));
+extern void cfree (void *__ptr) __THROW;
 #endif /* Use misc.  */
 
 #if defined __USE_GNU || defined __USE_BSD || defined __USE_MISC
@@ -494,67 +492,67 @@ extern void cfree __P ((__ptr_t __ptr));
 
 #if defined __USE_BSD || defined __USE_XOPEN_EXTENDED
 /* Allocate SIZE bytes on a page boundary.  The storage cannot be freed.  */
-extern __ptr_t valloc __P ((size_t __size));
+extern void *valloc (size_t __size) __THROW;
 #endif
 
 
 /* Abort execution and generate a core-dump.  */
-extern void abort __P ((void)) __attribute__ ((__noreturn__));
+extern void abort (void) __THROW __attribute__ ((__noreturn__));
 
 
 /* Register a function to be called when `exit' is called.  */
-extern int atexit __P ((void (*__func) (void)));
+extern int atexit (void (*__func) (void)) __THROW;
 
 #ifdef	__USE_MISC
 /* Register a function to be called with the status
    given to `exit' and the given argument.  */
-extern int __on_exit __P ((void (*__func) (int __status, __ptr_t __arg),
-			   __ptr_t __arg));
-extern int on_exit __P ((void (*__func) (int __status, __ptr_t __arg),
-			 __ptr_t __arg));
+extern int __on_exit (void (*__func) (int __status, void *__arg), void *__arg)
+     __THROW;
+extern int on_exit (void (*__func) (int __status, void *__arg), void *__arg)
+     __THROW;
 #endif
 
 /* Call all functions registered with `atexit' and `on_exit',
    in the reverse of the order in which they were registered
    perform stdio cleanup, and terminate program execution with STATUS.  */
-extern void exit __P ((int __status)) __attribute__ ((__noreturn__));
+extern void exit (int __status) __THROW __attribute__ ((__noreturn__));
 
 #ifdef __USE_ISOC9X
 /* Terminate the program with STATUS without calling any of the
    functions registered with `atexit' or `on_exit'.  */
-extern void _Exit __P ((int __status)) __attribute__ ((__noreturn__));
+extern void _Exit (int __status) __THROW __attribute__ ((__noreturn__));
 #endif
 
 
 /* Return the value of envariable NAME, or NULL if it doesn't exist.  */
-extern char *getenv __P ((__const char *__name));
+extern char *getenv (__const char *__name) __THROW;
 
 /* This function is similar to the above but returns NULL if the
    programs is running with SUID or SGID enabled.  */
-extern char *__secure_getenv __P ((__const char *__name));
+extern char *__secure_getenv (__const char *__name) __THROW;
 
 #if defined __USE_SVID || defined __USE_XOPEN
 /* The SVID says this is in <stdio.h>, but this seems a better place.	*/
 /* Put STRING, which is of the form "NAME=VALUE", in the environment.
    If there is no `=', remove NAME from the environment.  */
-extern int putenv __P ((char *__string));
+extern int putenv (char *__string) __THROW;
 #endif
 
 #ifdef	__USE_BSD
 /* Set NAME to VALUE in the environment.
    If REPLACE is nonzero, overwrite an existing value.  */
-extern int setenv __P ((__const char *__name, __const char *__value,
-			int __replace));
+extern int setenv (__const char *__name, __const char *__value, int __replace)
+     __THROW;
 
 /* Remove the variable NAME from the environment.  */
-extern void unsetenv __P ((__const char *__name));
+extern void unsetenv (__const char *__name) __THROW;
 #endif
 
 #ifdef	__USE_MISC
 /* The `clearenv' was planned to be added to POSIX.1 but probably
    never made it.  Nevertheless the POSIX.9 standard (POSIX bindings
    for Fortran 77) requires this function.  */
-extern int clearenv __P ((void));
+extern int clearenv (void) __THROW;
 #endif
 
 
@@ -563,14 +561,14 @@ extern int clearenv __P ((void));
    The last six characters of TEMPLATE must be "XXXXXX";
    they are replaced with a string that makes the file name unique.
    Returns TEMPLATE, or a null pointer if it cannot get a unique file name.  */
-extern char *mktemp __P ((char *__template));
+extern char *mktemp (char *__template) __THROW;
 
 /* Generate a unique temporary file name from TEMPLATE.
    The last six characters of TEMPLATE must be "XXXXXX";
    they are replaced with a string that makes the filename unique.
    Returns a file descriptor open on the file for reading and writing,
    or -1 if it cannot create a uniquely-named file.  */
-extern int mkstemp __P ((char *__template));
+extern int mkstemp (char *__template) __THROW;
 #endif
 
 #ifdef __USE_BSD
@@ -579,19 +577,19 @@ extern int mkstemp __P ((char *__template));
    they are replaced with a string that makes the directory name unique.
    Returns TEMPLATE, or a null pointer if it cannot get a unique name.
    The directory is created mode 700.  */
-extern char *mkdtemp __P ((char *__template));
+extern char *mkdtemp (char *__template) __THROW;
 #endif
 
 
 /* Execute the given line as a shell command.  */
-extern int system __P ((__const char *__command));
+extern int system (__const char *__command) __THROW;
 
 
 #ifdef	__USE_GNU
 /* Return a malloc'd string containing the canonical absolute name of the
    named file.  The last file name component need not exist, and may be a
    symlink to a nonexistent file.  */
-extern char *canonicalize_file_name __P ((__const char *__name));
+extern char *canonicalize_file_name (__const char *__name) __THROW;
 #endif
 
 #if defined __USE_BSD || defined __USE_XOPEN_EXTENDED
@@ -601,15 +599,15 @@ extern char *canonicalize_file_name __P ((__const char *__name));
    name is PATH_MAX chars or more, returns null with `errno' set to
    ENAMETOOLONG; if the name fits in fewer than PATH_MAX chars, returns the
    name in RESOLVED.  */
-extern char *realpath __P ((__const char *__restrict __name,
-			    char *__restrict __resolved));
+extern char *realpath (__const char *__restrict __name,
+		       char *__restrict __resolved) __THROW;
 #endif
 
 
 /* Shorthand for type of comparison functions.  */
 #ifndef __COMPAR_FN_T
 # define __COMPAR_FN_T
-typedef int (*__compar_fn_t) __PMT ((__const __ptr_t, __const __ptr_t));
+typedef int (*__compar_fn_t) (__const void *, __const void *);
 
 # ifdef	__USE_GNU
 typedef __compar_fn_t comparison_fn_t;
@@ -618,35 +616,35 @@ typedef __compar_fn_t comparison_fn_t;
 
 /* Do a binary search for KEY in BASE, which consists of NMEMB elements
    of SIZE bytes each, using COMPAR to perform the comparisons.  */
-extern __ptr_t bsearch __PMT ((__const __ptr_t __key, __const __ptr_t __base,
-			       size_t __nmemb, size_t __size,
-			       __compar_fn_t __compar));
+extern void *bsearch (__const void *__key, __const void *__base,
+		      size_t __nmemb, size_t __size, __compar_fn_t __compar);
 
 /* Sort NMEMB elements of BASE, of SIZE bytes each,
    using COMPAR to perform the comparisons.  */
-extern void qsort __PMT ((__ptr_t __base, size_t __nmemb, size_t __size,
-			  __compar_fn_t __compar));
+extern void qsort (void *__base, size_t __nmemb, size_t __size,
+		   __compar_fn_t __compar);
 
 
 /* Return the absolute value of X.  */
-extern int abs __P ((int __x)) __attribute__ ((__const__));
-extern long int labs __P ((long int __x)) __attribute__ ((__const__));
+extern int abs (int __x) __THROW __attribute__ ((__const__));
+extern long int labs (long int __x) __THROW __attribute__ ((__const__));
 #ifdef __USE_ISOC9X
-__extension__ extern long long int llabs __P ((long long int __x))
-     __attribute__ ((__const__));
+__extension__ extern long long int llabs (long long int __x)
+     __THROW __attribute__ ((__const__));
 #endif
 
 
 /* Return the `div_t', `ldiv_t' or `lldiv_t' representation
    of the value of NUMER over DENOM. */
 /* GCC may have built-ins for these someday.  */
-extern div_t div __P ((int __numer, int __denom)) __attribute__ ((__const__));
-extern ldiv_t ldiv __P ((long int __numer, long int __denom))
-     __attribute__ ((__const__));
+extern div_t div (int __numer, int __denom)
+     __THROW __attribute__ ((__const__));
+extern ldiv_t ldiv (long int __numer, long int __denom)
+     __THROW __attribute__ ((__const__));
 #ifdef __USE_ISOC9X
-__extension__ extern lldiv_t lldiv __P ((long long int __numer,
-					 long long int __denom))
-     __attribute__ ((__const__));
+__extension__ extern lldiv_t lldiv (long long int __numer,
+				    long long int __denom)
+     __THROW __attribute__ ((__const__));
 #endif
 
 
@@ -657,66 +655,67 @@ __extension__ extern lldiv_t lldiv __P ((long long int __numer,
 /* Convert VALUE to a string with NDIGIT digits and return a pointer to
    this.  Set *DECPT with the position of the decimal character and *SIGN
    with the sign of the number.  */
-extern char *ecvt __P ((double __value, int __ndigit, int *__restrict __decpt,
-			int *__restrict __sign));
+extern char *ecvt (double __value, int __ndigit, int *__restrict __decpt,
+		   int *__restrict __sign) __THROW;
 
 /* Convert VALUE to a string rounded to NDIGIT decimal digits.  Set *DECPT
    with the position of the decimal character and *SIGN with the sign of
    the number.  */
-extern char *fcvt __P ((double __value, int __ndigit, int *__restrict __decpt,
-			int *__restrict __sign));
+extern char *fcvt (double __value, int __ndigit, int *__restrict __decpt,
+		   int *__restrict __sign) __THROW;
 
 /* If possible convert VALUE to a string with NDIGIT significant digits.
    Otherwise use exponential representation.  The resulting string will
    be written to BUF.  */
-extern char *gcvt __P ((double __value, int __ndigit, char *__buf));
+extern char *gcvt (double __value, int __ndigit, char *__buf) __THROW;
 
 /* Long double versions of above functions.  */
-extern char *qecvt __P ((__long_double_t __value, int __ndigit,
-			 int *__restrict __decpt, int *__restrict __sign));
-extern char *qfcvt __P ((__long_double_t __value, int __ndigit,
-			 int *__restrict __decpt, int *__restrict __sign));
-extern char *qgcvt __P ((__long_double_t __value, int __ndigit, char *__buf));
+extern char *qecvt (long double __value, int __ndigit,
+		    int *__restrict __decpt, int *__restrict __sign) __THROW;
+extern char *qfcvt (long double __value, int __ndigit,
+		    int *__restrict __decpt, int *__restrict __sign) __THROW;
+extern char *qgcvt (long double __value, int __ndigit, char *__buf) __THROW;
 
 
 # ifdef __USE_MISC
 /* Reentrant version of the functions above which provide their own
    buffers.  */
-extern int ecvt_r __P ((double __value, int __ndigit, int *__restrict __decpt,
-			int *__restrict __sign, char *__restrict __buf,
-			size_t __len));
-extern int fcvt_r __P ((double __value, int __ndigit, int *__restrict __decpt,
-			int *__restrict __sign, char *__restrict __buf,
-			size_t __len));
-
-extern int qecvt_r __P ((__long_double_t __value, int __ndigit,
-			 int *__restrict __decpt, int *__restrict __sign,
-			 char *__restrict __buf, size_t __len));
-extern int qfcvt_r __P ((__long_double_t __value, int __ndigit,
-			 int *__restrict __decpt, int *__restrict __sign,
-			 char *__restrict __buf, size_t __len));
+extern int ecvt_r (double __value, int __ndigit, int *__restrict __decpt,
+		   int *__restrict __sign, char *__restrict __buf,
+		   size_t __len) __THROW;
+extern int fcvt_r (double __value, int __ndigit, int *__restrict __decpt,
+		   int *__restrict __sign, char *__restrict __buf,
+		   size_t __len) __THROW;
+
+extern int qecvt_r (long double __value, int __ndigit,
+		    int *__restrict __decpt, int *__restrict __sign,
+		    char *__restrict __buf, size_t __len) __THROW;
+extern int qfcvt_r (long double __value, int __ndigit,
+		    int *__restrict __decpt, int *__restrict __sign,
+		    char *__restrict __buf, size_t __len) __THROW;
 # endif	/* misc */
 #endif	/* use MISC || use X/Open Unix */
 
 
 /* Return the length of the multibyte character
    in S, which is no longer than N.  */
-extern int mblen __P ((__const char *__s, size_t __n));
+extern int mblen (__const char *__s, size_t __n) __THROW;
 /* Return the length of the given multibyte character,
    putting its `wchar_t' representation in *PWC.  */
-extern int mbtowc __P ((wchar_t *__restrict __pwc,
-			__const char *__restrict __s, size_t __n));
+extern int mbtowc (wchar_t *__restrict __pwc,
+		   __const char *__restrict __s, size_t __n) __THROW;
 /* Put the multibyte character represented
    by WCHAR in S, returning its length.  */
-extern int wctomb __P ((char *__s, wchar_t __wchar));
+extern int wctomb (char *__s, wchar_t __wchar) __THROW;
 
 
 /* Convert a multibyte string to a wide char string.  */
-extern size_t mbstowcs __P ((wchar_t *__restrict  __pwcs,
-			     __const char *__restrict __s, size_t __n));
+extern size_t mbstowcs (wchar_t *__restrict  __pwcs,
+			__const char *__restrict __s, size_t __n) __THROW;
 /* Convert a wide char string to multibyte string.  */
-extern size_t wcstombs __P ((char *__restrict __s,
-			     __const wchar_t *__restrict __pwcs, size_t __n));
+extern size_t wcstombs (char *__restrict __s,
+			__const wchar_t *__restrict __pwcs, size_t __n)
+     __THROW;
 
 
 #ifdef __USE_SVID
@@ -724,7 +723,7 @@ extern size_t wcstombs __P ((char *__restrict __s,
    or negative response expression as specified by the LC_MESSAGES category
    in the program's current locale.  Returns 1 if affirmative, 0 if
    negative, and -1 if not matching.  */
-extern int rpmatch __P ((__const char *__response));
+extern int rpmatch (__const char *__response) __THROW;
 #endif
 
 
@@ -735,16 +734,16 @@ extern int rpmatch __P ((__const char *__response));
    not part of TOKENS return in *VALUEP beginning of unknown
    suboption.  On exit *OPTIONP is set to the beginning of the next
    token or at the terminating NUL character.  */
-extern int getsubopt __P ((char **__restrict __optionp,
-			   char *__const *__restrict __tokens,
-			   char **__restrict __valuep));
+extern int getsubopt (char **__restrict __optionp,
+		      char *__const *__restrict __tokens,
+		      char **__restrict __valuep) __THROW;
 #endif
 
 
 #ifdef __USE_XOPEN
 
 /* Setup DES tables according KEY.  */
-extern void setkey __P ((__const char *__key));
+extern void setkey (__const char *__key) __THROW;
 
 /* X/Open pseudo terminal handling.  */
 
@@ -752,33 +751,33 @@ extern void setkey __P ((__const char *__key));
    perform an operation on the associated slave:  */
 
 /* Chown the slave to the calling user.  */
-extern int grantpt __P ((int __fd));
+extern int grantpt (int __fd) __THROW;
 
 /* Release an internal lock so the slave can be opened.
    Call after grantpt().  */
-extern int unlockpt __P ((int __fd));
+extern int unlockpt (int __fd) __THROW;
 
 /* Return the pathname of the pseudo terminal slave assoicated with
    the master FD is open on, or NULL on errors.
    The returned storage is good until the next call to this function.  */
-extern char *ptsname __P ((int __fd));
+extern char *ptsname (int __fd) __THROW;
 #endif
 
 #ifdef __USE_GNU
 /* Store at most BUFLEN characters of the pathname of the slave pseudo
    terminal associated with the master FD is open on in BUF.
    Return 0 on success, otherwise an error number.  */
-extern int ptsname_r __P ((int __fd, char *__buf, size_t __buflen));
+extern int ptsname_r (int __fd, char *__buf, size_t __buflen) __THROW;
 
 /* Open a master pseudo terminal and return its file descriptor.  */
-extern int getpt __P ((void));
+extern int getpt (void) __THROW;
 #endif
 
 #ifdef __USE_BSD
 /* Put the 1 minute, 5 minute and 15 minute load averages into the first
    NELEM elements of LOADAVG.  Return the number written (never more than
    three, but may be less than NELEM), or -1 if an error occurred.  */
-extern int getloadavg __P ((double __loadavg[], int __nelem));
+extern int getloadavg (double __loadavg[], int __nelem) __THROW;
 #endif
 
 #endif /* don't just need malloc and calloc */
diff --git a/stdlib/ucontext.h b/stdlib/ucontext.h
index d99e95e652..9e92a61cbf 100644
--- a/stdlib/ucontext.h
+++ b/stdlib/ucontext.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 1997, 1998 Free Software Foundation, Inc.
+/* Copyright (C) 1997, 1998, 1999 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -29,14 +29,14 @@
 __BEGIN_DECLS
 
 /* Get user context and store it in variable pointed to by UCP.  */
-extern int getcontext __P ((ucontext_t *__ucp));
+extern int getcontext (ucontext_t *__ucp) __THROW;
 
 /* Set user context from information of variable pointed to by UCP.  */
-extern int setcontext __P ((__const ucontext_t *__ucp));
+extern int setcontext (__const ucontext_t *__ucp) __THROW;
 
 /* Save current context in context variable pointed to by OUCP and set
    context from variable pointed to by UCP.  */
-extern int swapcontext __P ((ucontext_t *__oucp, __const ucontext_t *__ucp));
+extern int swapcontext (ucontext_t *__oucp, __const ucontext_t *__ucp) __THROW;
 
 /* Manipulate user context UCP to continue with calling functions FUNC
    and the ARGC-1 parameters following ARGC when the context is used
@@ -44,8 +44,8 @@ extern int swapcontext __P ((ucontext_t *__oucp, __const ucontext_t *__ucp));
 
    We cannot say anything about the parameters FUNC takes; `void'
    is as good as any other choice.  */
-extern void makecontext __P ((ucontext_t *__ucp, void (*__func) (void),
-			      int __argc, ...));
+extern void makecontext (ucontext_t *__ucp, void (*__func) (void),
+			 int __argc, ...) __THROW;
 
 __END_DECLS