From e726332fedf54220895766325c635565892fc70d Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Fri, 17 Jan 2025 22:11:54 -0800 Subject: [PATCH] alignasof: port to IBM XL C V16.1 * m4/stdalign.m4 (gl_ALIGNASOF): Work around similar bug in IBM XL C V16.1.0 cc (non-clang). Since this is the last version of this obsolescent compiler, assume the bug is in earlier versions. --- ChangeLog | 8 ++++++++ m4/stdalign.m4 | 10 ++++++---- 2 files changed, 14 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index 88e92dde57..5675ef35e9 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2025-01-17 Paul Eggert + + alignasof: port to IBM XL C V16.1 + * m4/stdalign.m4 (gl_ALIGNASOF): + Work around similar bug in IBM XL C V16.1.0 cc (non-clang). + Since this is the last version of this obsolescent compiler, + assume the bug is in earlier versions. + 2025-01-17 Pádraig Brady Avoid -Wformat=security failures with --disable-nls diff --git a/m4/stdalign.m4 b/m4/stdalign.m4 index 1c29d1e4fb..07599cc6da 100644 --- a/m4/stdalign.m4 +++ b/m4/stdalign.m4 @@ -1,6 +1,6 @@ # stdalign.m4 -# serial 1 -dnl Copyright 2011-2024 Free Software Foundation, Inc. +# serial 2 +dnl Copyright 2011-2025 Free Software Foundation, Inc. dnl This file is free software; the Free Software Foundation dnl gives unlimited permission to copy and/or distribute it, dnl with or without modifications, as long as this notice is preserved. @@ -103,11 +103,13 @@ AC_DEFUN([gl_ALIGNASOF], /* GCC releases before GCC 4.9 had a bug in _Alignof. See GCC bug 52023 . - clang versions < 8.0.0 have the same bug. */ + clang versions < 8.0.0 have the same bug. + IBM XL C V16.1.0 cc (non-clang) has the same bug. */ # if (!defined __STDC_VERSION__ || __STDC_VERSION__ < 201112 \ || (defined __GNUC__ && __GNUC__ < 4 + (__GNUC_MINOR__ < 9) \ && !defined __clang__) \ - || (defined __clang__ && __clang_major__ < 8)) + || (defined __clang__ && __clang_major__ < 8) \ + || defined __xlC__) # undef/**/_Alignof # ifdef __cplusplus # if (201103 <= __cplusplus || defined _MSC_VER) -- 2.39.5