aboutsummaryrefslogtreecommitdiffstats
path: root/lib/string.in.h
diff options
context:
space:
mode:
authorPaul Eggert2020-08-11 10:58:35 -0700
committerPaul Eggert2020-08-11 11:07:28 -0700
commit124a7951f495b916cf38f0e1e1fe85e22bc08aba (patch)
tree7da6fb7a3ae571652acb36418706654fd54d7dc0 /lib/string.in.h
parent669aeafbd14b0ebb824bacba0a6b3daad30847a9 (diff)
downloademacs-124a7951f495b916cf38f0e1e1fe85e22bc08aba.tar.gz
emacs-124a7951f495b916cf38f0e1e1fe85e22bc08aba.zip
Update from Gnulib
This incorporates: 2020-08-11 Use expression statements also on clang 2020-08-10 Use many __attribute__s with clang 2020-08-09 Use attribute __aligned__ with clang 2020-08-09 Use __alignof__ with clang 2020-08-09 ignore-value: Simplify on clang 2020-08-09 Use __typeof__ with clang 2020-08-09 intprops: Fix typo in comment 2020-08-09 Silence warnings from clang 10 with -Wimplicit-fallthrough 2020-08-09 count-one-bits: Use __builtin_popcount{,l,ll} on clang 2020-08-09 string: Fix build error in C++ mode with clang 2020-08-09 Add ability to emit user-defined diagnostics with clang 2020-08-07 alloca: No need to compile alloca.c with clang 2020-08-06 Use __builtin_assume with clang * lib/alloca.in.h, lib/arg-nonnull.h, lib/c++defs.h, lib/cdefs.h: * lib/count-one-bits.h, lib/dirent.in.h, lib/ignore-value.h: * lib/intprops.h, lib/malloca.h, lib/regex_internal.h: * lib/stdalign.in.h, lib/stddef.in.h, lib/stdio.in.h: * lib/stdlib.in.h, lib/string.in.h, lib/verify.h, lib/warn-on-use.h: * m4/gnulib-common.m4, m4/stddef_h.m4, m4/stdint.m4: Copy from Gnulib.
Diffstat (limited to 'lib/string.in.h')
-rw-r--r--lib/string.in.h14
1 files changed, 9 insertions, 5 deletions
diff --git a/lib/string.in.h b/lib/string.in.h
index aa9802791ee..c0c1a54f39d 100644
--- a/lib/string.in.h
+++ b/lib/string.in.h
@@ -55,7 +55,7 @@
55/* The __attribute__ feature is available in gcc versions 2.5 and later. 55/* The __attribute__ feature is available in gcc versions 2.5 and later.
56 The attribute __pure__ was added in gcc 2.96. */ 56 The attribute __pure__ was added in gcc 2.96. */
57#ifndef _GL_ATTRIBUTE_PURE 57#ifndef _GL_ATTRIBUTE_PURE
58# if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 96) 58# if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 96) || defined __clang__
59# define _GL_ATTRIBUTE_PURE __attribute__ ((__pure__)) 59# define _GL_ATTRIBUTE_PURE __attribute__ ((__pure__))
60# else 60# else
61# define _GL_ATTRIBUTE_PURE /* empty */ 61# define _GL_ATTRIBUTE_PURE /* empty */
@@ -329,7 +329,8 @@ _GL_WARN_ON_USE (stpncpy, "stpncpy is unportable - "
329 GB18030 and the character to be searched is a digit. */ 329 GB18030 and the character to be searched is a digit. */
330# undef strchr 330# undef strchr
331/* Assume strchr is always declared. */ 331/* Assume strchr is always declared. */
332_GL_WARN_ON_USE_CXX (strchr, const char *, (const char *, int), 332_GL_WARN_ON_USE_CXX (strchr,
333 const char *, char *, (const char *, int),
333 "strchr cannot work correctly on character strings " 334 "strchr cannot work correctly on character strings "
334 "in some multibyte locales - " 335 "in some multibyte locales - "
335 "use mbschr if you care about internationalization"); 336 "use mbschr if you care about internationalization");
@@ -524,7 +525,8 @@ _GL_CXXALIASWARN (strpbrk);
524 locale encoding is GB18030 and one of the characters to be searched is a 525 locale encoding is GB18030 and one of the characters to be searched is a
525 digit. */ 526 digit. */
526# undef strpbrk 527# undef strpbrk
527_GL_WARN_ON_USE_CXX (strpbrk, const char *, (const char *, const char *), 528_GL_WARN_ON_USE_CXX (strpbrk,
529 const char *, char *, (const char *, const char *),
528 "strpbrk cannot work correctly on character strings " 530 "strpbrk cannot work correctly on character strings "
529 "in multibyte locales - " 531 "in multibyte locales - "
530 "use mbspbrk if you care about internationalization"); 532 "use mbspbrk if you care about internationalization");
@@ -532,7 +534,8 @@ _GL_WARN_ON_USE_CXX (strpbrk, const char *, (const char *, const char *),
532#elif defined GNULIB_POSIXCHECK 534#elif defined GNULIB_POSIXCHECK
533# undef strpbrk 535# undef strpbrk
534# if HAVE_RAW_DECL_STRPBRK 536# if HAVE_RAW_DECL_STRPBRK
535_GL_WARN_ON_USE_CXX (strpbrk, const char *, (const char *, const char *), 537_GL_WARN_ON_USE_CXX (strpbrk,
538 const char *, char *, (const char *, const char *),
536 "strpbrk is unportable - " 539 "strpbrk is unportable - "
537 "use gnulib module strpbrk for portability"); 540 "use gnulib module strpbrk for portability");
538# endif 541# endif
@@ -553,7 +556,8 @@ _GL_WARN_ON_USE (strspn, "strspn cannot work correctly on character strings "
553 GB18030 and the character to be searched is a digit. */ 556 GB18030 and the character to be searched is a digit. */
554# undef strrchr 557# undef strrchr
555/* Assume strrchr is always declared. */ 558/* Assume strrchr is always declared. */
556_GL_WARN_ON_USE_CXX (strrchr, const char *, (const char *, int), 559_GL_WARN_ON_USE_CXX (strrchr,
560 const char *, char *, (const char *, int),
557 "strrchr cannot work correctly on character strings " 561 "strrchr cannot work correctly on character strings "
558 "in some multibyte locales - " 562 "in some multibyte locales - "
559 "use mbsrchr if you care about internationalization"); 563 "use mbsrchr if you care about internationalization");