]> Savannah Git Hosting - gnulib.git/commitdiff
attribute: keep up with gnulib-common.m4
authorPaul Eggert <eggert@cs.ucla.edu>
Mon, 30 Aug 2021 00:50:56 +0000 (17:50 -0700)
committerPaul Eggert <eggert@cs.ucla.edu>
Mon, 30 Aug 2021 00:51:28 +0000 (17:51 -0700)
* lib/attribute.h (ATTRIBUTE_DEALLOC, ATTRIBUTE_DEALLOC_FREE):
New macros, aliases for the _GL_-prefixed macros added
to gnulib-common.m4 last month.

ChangeLog
lib/attribute.h

index df3f0481f6e8c22a5ad3826873465c0c1fedc5bd..b86a6c33a796040c175363993beaf7ee35a8497a 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2021-08-29  Paul Eggert  <eggert@cs.ucla.edu>
+
+       attribute: keep up with gnulib-common.m4
+       * lib/attribute.h (ATTRIBUTE_DEALLOC, ATTRIBUTE_DEALLOC_FREE):
+       New macros, aliases for the _GL_-prefixed macros added
+       to gnulib-common.m4 last month.
+
 2021-08-29  Bruno Haible  <bruno@clisp.org>
 
        supersede: Fix test failure under QEMU user-mode for Linux/mips.
index 80a23f550cd0603a24b3cbe4749168ef40f42d15..26a5556557badf1b500323d22ef126c564f6d093 100644 (file)
 /* Applies to: function, pointer to function, function types.  */
 #define ATTRIBUTE_ALLOC_SIZE(args) _GL_ATTRIBUTE_ALLOC_SIZE (args)
 
+/* ATTRIBUTE_DEALLOC (F, I) declares that the function returns pointers
+   that can be freed by passing them as the Ith argument to the
+   function F.
+   ATTRIBUTE_DEALLOC_FREE declares that the function returns pointers that
+   can be freed via 'free'; it can be used only after including <stdlib.h>.  */
+/* Applies to: functions.  Cannot be used on inline functions.  */
+#define ATTRIBUTE_DEALLOC(f, i) _GL_ATTRIBUTE_DEALLOC(f, i)
+#define ATTRIBUTE_DEALLOC_FREE _GL_ATTRIBUTE_DEALLOC_FREE
 
 /* Attributes for variadic functions.  */