From 9b5002be4f5bd03783a59f433c713a6ed7d9171c Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Wed, 17 Aug 2016 17:24:11 -0700 Subject: [PATCH] regex, string: rename to avoid '__string' * lib/regex.h, lib/string.in.h: Do not use the identifier '__string', as it is effectively reserved by string.h on z/OS. --- ChangeLog | 4 ++++ lib/regex.h | 6 +++--- lib/string.in.h | 16 ++++++++-------- 3 files changed, 15 insertions(+), 11 deletions(-) diff --git a/ChangeLog b/ChangeLog index c9579b29ec..5e9faa25d8 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,9 @@ 2016-08-17 Paul Eggert + regex, string: rename to avoid '__string' + * lib/regex.h, lib/string.in.h: Do not use the identifier + '__string', as it is effectively reserved by string.h on z/OS. + c-strcase-tests, wcwidth-tests: depend on c-ctype * modules/c-strcase-tests, modules/wcwidth-tests (Depends-on): Add c-ctype. diff --git a/lib/regex.h b/lib/regex.h index 3ba64ac89d..03ea9a8bb1 100644 --- a/lib/regex.h +++ b/lib/regex.h @@ -552,7 +552,7 @@ extern int re_compile_fastmap (struct re_pattern_buffer *__buffer); match, or -2 for an internal error. Also return register information in REGS (if REGS and BUFFER->no_sub are nonzero). */ extern regoff_t re_search (struct re_pattern_buffer *__buffer, - const char *__string, regoff_t __length, + const char *__String, regoff_t __length, regoff_t __start, regoff_t __range, struct re_registers *__regs); @@ -570,7 +570,7 @@ extern regoff_t re_search_2 (struct re_pattern_buffer *__buffer, /* Like 're_search', but return how many characters in STRING the regexp in BUFFER matched, starting at position START. */ extern regoff_t re_match (struct re_pattern_buffer *__buffer, - const char *__string, regoff_t __length, + const char *__String, regoff_t __length, regoff_t __start, struct re_registers *__regs); @@ -642,7 +642,7 @@ extern int regcomp (regex_t *_Restrict_ __preg, int __cflags); extern int regexec (const regex_t *_Restrict_ __preg, - const char *_Restrict_ __string, size_t __nmatch, + const char *_Restrict_ __String, size_t __nmatch, regmatch_t __pmatch[_Restrict_arr_], int __eflags); diff --git a/lib/string.in.h b/lib/string.in.h index 83288bceda..db861db37b 100644 --- a/lib/string.in.h +++ b/lib/string.in.h @@ -416,15 +416,15 @@ _GL_WARN_ON_USE (strncat, "strncat is unportable - " # undef strndup # define strndup rpl_strndup # endif -_GL_FUNCDECL_RPL (strndup, char *, (char const *__string, size_t __n) +_GL_FUNCDECL_RPL (strndup, char *, (char const *__s, size_t __n) _GL_ARG_NONNULL ((1))); -_GL_CXXALIAS_RPL (strndup, char *, (char const *__string, size_t __n)); +_GL_CXXALIAS_RPL (strndup, char *, (char const *__s, size_t __n)); # else # if ! @HAVE_DECL_STRNDUP@ -_GL_FUNCDECL_SYS (strndup, char *, (char const *__string, size_t __n) +_GL_FUNCDECL_SYS (strndup, char *, (char const *__s, size_t __n) _GL_ARG_NONNULL ((1))); # endif -_GL_CXXALIAS_SYS (strndup, char *, (char const *__string, size_t __n)); +_GL_CXXALIAS_SYS (strndup, char *, (char const *__s, size_t __n)); # endif _GL_CXXALIASWARN (strndup); #elif defined GNULIB_POSIXCHECK @@ -444,17 +444,17 @@ _GL_WARN_ON_USE (strndup, "strndup is unportable - " # undef strnlen # define strnlen rpl_strnlen # endif -_GL_FUNCDECL_RPL (strnlen, size_t, (char const *__string, size_t __maxlen) +_GL_FUNCDECL_RPL (strnlen, size_t, (char const *__s, size_t __maxlen) _GL_ATTRIBUTE_PURE _GL_ARG_NONNULL ((1))); -_GL_CXXALIAS_RPL (strnlen, size_t, (char const *__string, size_t __maxlen)); +_GL_CXXALIAS_RPL (strnlen, size_t, (char const *__s, size_t __maxlen)); # else # if ! @HAVE_DECL_STRNLEN@ -_GL_FUNCDECL_SYS (strnlen, size_t, (char const *__string, size_t __maxlen) +_GL_FUNCDECL_SYS (strnlen, size_t, (char const *__s, size_t __maxlen) _GL_ATTRIBUTE_PURE _GL_ARG_NONNULL ((1))); # endif -_GL_CXXALIAS_SYS (strnlen, size_t, (char const *__string, size_t __maxlen)); +_GL_CXXALIAS_SYS (strnlen, size_t, (char const *__s, size_t __maxlen)); # endif _GL_CXXALIASWARN (strnlen); #elif defined GNULIB_POSIXCHECK -- 2.39.5