summaryrefslogtreecommitdiff
path: root/m4/gnulib-common.m4
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2021-09-07 17:51:39 -0700
committerPaul Eggert <eggert@cs.ucla.edu>2021-09-07 17:56:01 -0700
commita4a2d039a9117266ed8cb1977241e7c34b368993 (patch)
treea22569b38117ddc2c4d38ad74176d8968bdaa638 /m4/gnulib-common.m4
parent2c062d406a8ce00165b3b78c765e7f6a07ec8615 (diff)
downloadgnulib-a4a2d039a9117266ed8cb1977241e7c34b368993.tar.gz
string, wchar: avoid some namespace pollution
* lib/string.in.h, lib/wchar.in.h: (free): Declare by hand instead of including stdlib.h. This avoids some namespace pollution. It should also avoid some nested-include problems described by Lucy Phipps in: https://lists.gnu.org/r/bug-gnulib/2021-09/msg00018.html * modules/string, modules/wchar: (Depends-on): Add stdlib, so that REPLACE_FREE has the right value. (Makefile.am): Replace @REPLACE_FREE@ when creating the include file.
Diffstat (limited to 'm4/gnulib-common.m4')
-rw-r--r--m4/gnulib-common.m42
1 files changed, 1 insertions, 1 deletions
diff --git a/m4/gnulib-common.m4 b/m4/gnulib-common.m4
index 5d667052d9..12b19dbcb4 100644
--- a/m4/gnulib-common.m4
+++ b/m4/gnulib-common.m4
@@ -174,7 +174,7 @@ AC_DEFUN([gl_COMMON_BODY], [
that can be freed by passing them as the Ith argument to the
function F.
_GL_ATTRIBUTE_DEALLOC_FREE declares that the function returns pointers that
- can be freed via 'free'; it can be used only after including <stdlib.h>. */
+ can be freed via 'free'; it can be used only after declaring 'free'. */
/* Applies to: functions. Cannot be used on inline functions. */
#if _GL_GNUC_PREREQ (11, 0)
# define _GL_ATTRIBUTE_DEALLOC(f, i) __attribute__ ((__malloc__ (f, i)))