From 98bbee782bcc534cbc40eac3e317727d45826b48 Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Sun, 19 Jan 2025 23:24:26 -0800 Subject: [PATCH] flexmember: update comment --- lib/flexmember.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/flexmember.h b/lib/flexmember.h index 0168af0eca..b4d86c29fb 100644 --- a/lib/flexmember.h +++ b/lib/flexmember.h @@ -28,9 +28,10 @@ #include /* Nonzero multiple of alignment of TYPE, suitable for FLEXSIZEOF below. - On older platforms without _Alignof, use a pessimistic bound that is + If _Alignof might not exist or might not work correctly on + structs with flexible array members, use a pessimistic bound that is safe in practice even if FLEXIBLE_ARRAY_MEMBER is 1. - On newer platforms, use _Alignof to get a tighter bound. */ + Otherwise, use _Alignof to get a tighter bound. */ #if !defined __STDC_VERSION__ || __STDC_VERSION__ < 201112 || defined _Alignof # define FLEXALIGNOF(type) (sizeof (type) & ~ (sizeof (type) - 1)) -- 2.39.5