Suggested by Bruno Haible.
* tests/test-aligned-malloc.c (ALIGNMENT): Undefine without checking.
Mention that the #undef is for AIX which defines it beforehand in
<sys/socket.h>.
2025-04-12 Collin Funk <collin.funk1@gmail.com>
+ aligned-malloc tests: Simplify a macro definition and improve comment.
+ Suggested by Bruno Haible.
+ * tests/test-aligned-malloc.c (ALIGNMENT): Undefine without checking.
+ Mention that the #undef is for AIX which defines it beforehand in
+ <sys/socket.h>.
+
immutable: Simplify a macro definition and improve comment.
Suggested by Bruno Haible.
* lib/immutable.c (ALIGNMENT): Undefine without checking. Mention that
#include <stdint.h>
#include <stdlib.h>
-/* Avoid redefinition on AIX. */
-#ifdef ALIGNMENT
-# undef ALIGNMENT
-#endif
+/* AIX defines a macro ALIGNMENT in <sys/socket.h>. Undefine it. */
+#undef ALIGNMENT
#define ALIGNMENT 4
#define aligned_malloc aligned4_malloc
#define aligned_free aligned4_free