diff options
| author | Paul Eggert | 2020-02-23 01:24:21 -0800 |
|---|---|---|
| committer | Paul Eggert | 2020-02-23 01:27:19 -0800 |
| commit | b6be1ce644a07b6dc30eaa24dec082effd7add40 (patch) | |
| tree | 02de8983f45751bf5da9b2f409758f2934306746 /lib/stdlib.in.h | |
| parent | bce17355ac9f6a6f8ed778bd310f3baaea514270 (diff) | |
| download | emacs-b6be1ce644a07b6dc30eaa24dec082effd7add40.tar.gz emacs-b6be1ce644a07b6dc30eaa24dec082effd7add40.zip | |
Update from Gnulib
This incorporates:
2020-02-22 fchmodat, lchmod: simplify
2020-02-22 lchmod: fix link error on Solaris 10
2020-02-22 use 'restrict' in all POSIX function declarations
2020-02-22 chmodat, chownat: new modules
* lib/gnulib.mk.in: Regenerate.
* lib/inttypes.in.h, lib/openat.h, lib/signal.in.h:
* lib/stdio.in.h, lib/stdlib.in.h, lib/string.in.h:
* lib/sys_stat.in.h, lib/time.in.h, lib/unistd.in.h, m4/inttypes.m4:
* m4/signal_h.m4, m4/stdio_h.m4, m4/stdlib_h.m4, m4/string_h.m4:
* m4/sys_socket_h.m4, m4/sys_stat_h.m4, m4/time_h.m4:
* m4/unistd_h.m4: Copy from Gnulib.
Diffstat (limited to 'lib/stdlib.in.h')
| -rw-r--r-- | lib/stdlib.in.h | 72 |
1 files changed, 46 insertions, 26 deletions
diff --git a/lib/stdlib.in.h b/lib/stdlib.in.h index 49bbf6fccfb..ec5f124a366 100644 --- a/lib/stdlib.in.h +++ b/lib/stdlib.in.h | |||
| @@ -311,13 +311,17 @@ _GL_WARN_ON_USE (malloc, "malloc is not POSIX compliant everywhere - " | |||
| 311 | # undef mbtowc | 311 | # undef mbtowc |
| 312 | # define mbtowc rpl_mbtowc | 312 | # define mbtowc rpl_mbtowc |
| 313 | # endif | 313 | # endif |
| 314 | _GL_FUNCDECL_RPL (mbtowc, int, (wchar_t *pwc, const char *s, size_t n)); | 314 | _GL_FUNCDECL_RPL (mbtowc, int, |
| 315 | _GL_CXXALIAS_RPL (mbtowc, int, (wchar_t *pwc, const char *s, size_t n)); | 315 | (wchar_t *restrict pwc, const char *restrict s, size_t n)); |
| 316 | _GL_CXXALIAS_RPL (mbtowc, int, | ||
| 317 | (wchar_t *restrict pwc, const char *restrict s, size_t n)); | ||
| 316 | # else | 318 | # else |
| 317 | # if !@HAVE_MBTOWC@ | 319 | # if !@HAVE_MBTOWC@ |
| 318 | _GL_FUNCDECL_SYS (mbtowc, int, (wchar_t *pwc, const char *s, size_t n)); | 320 | _GL_FUNCDECL_SYS (mbtowc, int, |
| 321 | (wchar_t *restrict pwc, const char *restrict s, size_t n)); | ||
| 319 | # endif | 322 | # endif |
| 320 | _GL_CXXALIAS_SYS (mbtowc, int, (wchar_t *pwc, const char *s, size_t n)); | 323 | _GL_CXXALIAS_SYS (mbtowc, int, |
| 324 | (wchar_t *restrict pwc, const char *restrict s, size_t n)); | ||
| 321 | # endif | 325 | # endif |
| 322 | # if __GLIBC__ >= 2 | 326 | # if __GLIBC__ >= 2 |
| 323 | _GL_CXXALIASWARN (mbtowc); | 327 | _GL_CXXALIASWARN (mbtowc); |
| @@ -866,15 +870,19 @@ _GL_WARN_ON_USE (reallocarray, "reallocarray is not portable - " | |||
| 866 | # if !(defined __cplusplus && defined GNULIB_NAMESPACE) | 870 | # if !(defined __cplusplus && defined GNULIB_NAMESPACE) |
| 867 | # define realpath rpl_realpath | 871 | # define realpath rpl_realpath |
| 868 | # endif | 872 | # endif |
| 869 | _GL_FUNCDECL_RPL (realpath, char *, (const char *name, char *resolved) | 873 | _GL_FUNCDECL_RPL (realpath, char *, |
| 870 | _GL_ARG_NONNULL ((1))); | 874 | (const char *restrict name, char *restrict resolved) |
| 871 | _GL_CXXALIAS_RPL (realpath, char *, (const char *name, char *resolved)); | 875 | _GL_ARG_NONNULL ((1))); |
| 876 | _GL_CXXALIAS_RPL (realpath, char *, | ||
| 877 | (const char *restrict name, char *restrict resolved)); | ||
| 872 | # else | 878 | # else |
| 873 | # if !@HAVE_REALPATH@ | 879 | # if !@HAVE_REALPATH@ |
| 874 | _GL_FUNCDECL_SYS (realpath, char *, (const char *name, char *resolved) | 880 | _GL_FUNCDECL_SYS (realpath, char *, |
| 875 | _GL_ARG_NONNULL ((1))); | 881 | (const char *restrict name, char *restrict resolved) |
| 882 | _GL_ARG_NONNULL ((1))); | ||
| 876 | # endif | 883 | # endif |
| 877 | _GL_CXXALIAS_SYS (realpath, char *, (const char *name, char *resolved)); | 884 | _GL_CXXALIAS_SYS (realpath, char *, |
| 885 | (const char *restrict name, char *restrict resolved)); | ||
| 878 | # endif | 886 | # endif |
| 879 | _GL_CXXALIASWARN (realpath); | 887 | _GL_CXXALIASWARN (realpath); |
| 880 | #elif defined GNULIB_POSIXCHECK | 888 | #elif defined GNULIB_POSIXCHECK |
| @@ -957,15 +965,19 @@ _GL_WARN_ON_USE (setenv, "setenv is unportable - " | |||
| 957 | # define strtod rpl_strtod | 965 | # define strtod rpl_strtod |
| 958 | # endif | 966 | # endif |
| 959 | # define GNULIB_defined_strtod_function 1 | 967 | # define GNULIB_defined_strtod_function 1 |
| 960 | _GL_FUNCDECL_RPL (strtod, double, (const char *str, char **endp) | 968 | _GL_FUNCDECL_RPL (strtod, double, |
| 961 | _GL_ARG_NONNULL ((1))); | 969 | (const char *restrict str, char **restrict endp) |
| 962 | _GL_CXXALIAS_RPL (strtod, double, (const char *str, char **endp)); | 970 | _GL_ARG_NONNULL ((1))); |
| 971 | _GL_CXXALIAS_RPL (strtod, double, | ||
| 972 | (const char *restrict str, char **restrict endp)); | ||
| 963 | # else | 973 | # else |
| 964 | # if !@HAVE_STRTOD@ | 974 | # if !@HAVE_STRTOD@ |
| 965 | _GL_FUNCDECL_SYS (strtod, double, (const char *str, char **endp) | 975 | _GL_FUNCDECL_SYS (strtod, double, |
| 966 | _GL_ARG_NONNULL ((1))); | 976 | (const char *restrict str, char **restrict endp) |
| 977 | _GL_ARG_NONNULL ((1))); | ||
| 967 | # endif | 978 | # endif |
| 968 | _GL_CXXALIAS_SYS (strtod, double, (const char *str, char **endp)); | 979 | _GL_CXXALIAS_SYS (strtod, double, |
| 980 | (const char *restrict str, char **restrict endp)); | ||
| 969 | # endif | 981 | # endif |
| 970 | # if __GLIBC__ >= 2 | 982 | # if __GLIBC__ >= 2 |
| 971 | _GL_CXXALIASWARN (strtod); | 983 | _GL_CXXALIASWARN (strtod); |
| @@ -985,15 +997,19 @@ _GL_WARN_ON_USE (strtod, "strtod is unportable - " | |||
| 985 | # define strtold rpl_strtold | 997 | # define strtold rpl_strtold |
| 986 | # endif | 998 | # endif |
| 987 | # define GNULIB_defined_strtold_function 1 | 999 | # define GNULIB_defined_strtold_function 1 |
| 988 | _GL_FUNCDECL_RPL (strtold, long double, (const char *str, char **endp) | 1000 | _GL_FUNCDECL_RPL (strtold, long double, |
| 989 | _GL_ARG_NONNULL ((1))); | 1001 | (const char *restrict str, char **restrict endp) |
| 990 | _GL_CXXALIAS_RPL (strtold, long double, (const char *str, char **endp)); | 1002 | _GL_ARG_NONNULL ((1))); |
| 1003 | _GL_CXXALIAS_RPL (strtold, long double, | ||
| 1004 | (const char *restrict str, char **restrict endp)); | ||
| 991 | # else | 1005 | # else |
| 992 | # if !@HAVE_STRTOLD@ | 1006 | # if !@HAVE_STRTOLD@ |
| 993 | _GL_FUNCDECL_SYS (strtold, long double, (const char *str, char **endp) | 1007 | _GL_FUNCDECL_SYS (strtold, long double, |
| 994 | _GL_ARG_NONNULL ((1))); | 1008 | (const char *restrict str, char **restrict endp) |
| 1009 | _GL_ARG_NONNULL ((1))); | ||
| 995 | # endif | 1010 | # endif |
| 996 | _GL_CXXALIAS_SYS (strtold, long double, (const char *str, char **endp)); | 1011 | _GL_CXXALIAS_SYS (strtold, long double, |
| 1012 | (const char *restrict str, char **restrict endp)); | ||
| 997 | # endif | 1013 | # endif |
| 998 | _GL_CXXALIASWARN (strtold); | 1014 | _GL_CXXALIASWARN (strtold); |
| 999 | #elif defined GNULIB_POSIXCHECK | 1015 | #elif defined GNULIB_POSIXCHECK |
| @@ -1015,11 +1031,13 @@ _GL_WARN_ON_USE (strtold, "strtold is unportable - " | |||
| 1015 | to ERANGE. */ | 1031 | to ERANGE. */ |
| 1016 | # if !@HAVE_STRTOLL@ | 1032 | # if !@HAVE_STRTOLL@ |
| 1017 | _GL_FUNCDECL_SYS (strtoll, long long, | 1033 | _GL_FUNCDECL_SYS (strtoll, long long, |
| 1018 | (const char *string, char **endptr, int base) | 1034 | (const char *restrict string, char **restrict endptr, |
| 1035 | int base) | ||
| 1019 | _GL_ARG_NONNULL ((1))); | 1036 | _GL_ARG_NONNULL ((1))); |
| 1020 | # endif | 1037 | # endif |
| 1021 | _GL_CXXALIAS_SYS (strtoll, long long, | 1038 | _GL_CXXALIAS_SYS (strtoll, long long, |
| 1022 | (const char *string, char **endptr, int base)); | 1039 | (const char *restrict string, char **restrict endptr, |
| 1040 | int base)); | ||
| 1023 | _GL_CXXALIASWARN (strtoll); | 1041 | _GL_CXXALIASWARN (strtoll); |
| 1024 | #elif defined GNULIB_POSIXCHECK | 1042 | #elif defined GNULIB_POSIXCHECK |
| 1025 | # undef strtoll | 1043 | # undef strtoll |
| @@ -1040,11 +1058,13 @@ _GL_WARN_ON_USE (strtoll, "strtoll is unportable - " | |||
| 1040 | ERANGE. */ | 1058 | ERANGE. */ |
| 1041 | # if !@HAVE_STRTOULL@ | 1059 | # if !@HAVE_STRTOULL@ |
| 1042 | _GL_FUNCDECL_SYS (strtoull, unsigned long long, | 1060 | _GL_FUNCDECL_SYS (strtoull, unsigned long long, |
| 1043 | (const char *string, char **endptr, int base) | 1061 | (const char *restrict string, char **restrict endptr, |
| 1062 | int base) | ||
| 1044 | _GL_ARG_NONNULL ((1))); | 1063 | _GL_ARG_NONNULL ((1))); |
| 1045 | # endif | 1064 | # endif |
| 1046 | _GL_CXXALIAS_SYS (strtoull, unsigned long long, | 1065 | _GL_CXXALIAS_SYS (strtoull, unsigned long long, |
| 1047 | (const char *string, char **endptr, int base)); | 1066 | (const char *restrict string, char **restrict endptr, |
| 1067 | int base)); | ||
| 1048 | _GL_CXXALIASWARN (strtoull); | 1068 | _GL_CXXALIASWARN (strtoull); |
| 1049 | #elif defined GNULIB_POSIXCHECK | 1069 | #elif defined GNULIB_POSIXCHECK |
| 1050 | # undef strtoull | 1070 | # undef strtoull |