From 0bcfe62162c6317108fed5c0aabb5ce3d4a9a2aa Mon Sep 17 00:00:00 2001 From: ed Date: Tue, 13 Dec 2011 13:32:56 +0000 Subject: Replace __const by const in all non-contributed source code. As C1X is close to being released, there is no need to wrap around a feature that is already part of C90. Most of these files already use `const' in different placed as well. --- include/netdb.h | 2 +- include/regex.h | 2 +- include/signal.h | 6 +++--- include/stdio.h | 4 ++-- include/stdlib.h | 2 +- 5 files changed, 8 insertions(+), 8 deletions(-) (limited to 'include') diff --git a/include/netdb.h b/include/netdb.h index 2c2e4b3..9ed6e61 100644 --- a/include/netdb.h +++ b/include/netdb.h @@ -276,7 +276,7 @@ int getservbyport_r(int, const char *, struct servent *, char *, int getservent_r(struct servent *, char *, size_t, struct servent **); void herror(const char *); -__const char *hstrerror(int); +const char *hstrerror(int); int innetgr(const char *, const char *, const char *, const char *); void setnetgrent(const char *); #endif diff --git a/include/regex.h b/include/regex.h index fb9b99c..e8b185c 100644 --- a/include/regex.h +++ b/include/regex.h @@ -51,7 +51,7 @@ typedef __size_t size_t; typedef struct { int re_magic; size_t re_nsub; /* number of parenthesized subexpressions */ - __const char *re_endp; /* end pointer for REG_PEND */ + const char *re_endp; /* end pointer for REG_PEND */ struct re_guts *re_g; /* none of your business :-) */ } regex_t; diff --git a/include/signal.h b/include/signal.h index 32b9e6b..e7447df 100644 --- a/include/signal.h +++ b/include/signal.h @@ -42,9 +42,9 @@ * XXX should enlarge these, if only to give empty names instead of bounds * errors for large signal numbers. */ -extern __const char *__const sys_signame[NSIG]; -extern __const char *__const sys_siglist[NSIG]; -extern __const int sys_nsig; +extern const char * const sys_signame[NSIG]; +extern const char * const sys_siglist[NSIG]; +extern const int sys_nsig; #endif #if __POSIX_VISIBLE >= 200112 || __XSI_VISIBLE diff --git a/include/stdio.h b/include/stdio.h index bbeb0de..b72bfd4 100644 --- a/include/stdio.h +++ b/include/stdio.h @@ -404,8 +404,8 @@ int vasprintf(char **, const char *, __va_list) * positive errno values. Use strerror() or strerror_r() from * instead. */ -extern __const int sys_nerr; -extern __const char *__const sys_errlist[]; +extern const int sys_nerr; +extern const char * const sys_errlist[]; /* * Stdio function-access interface. diff --git a/include/stdlib.h b/include/stdlib.h index c19eef0..58362dd 100644 --- a/include/stdlib.h +++ b/include/stdlib.h @@ -271,7 +271,7 @@ char *devname_r(__dev_t, __mode_t, char *, int); char *fdevname(int); char *fdevname_r(int, char *, int); int getloadavg(double [], int); -__const char * +const char * getprogname(void); int heapsort(void *, size_t, size_t, int (*)(const void *, const void *)); -- cgit v1.1