summaryrefslogtreecommitdiff
path: root/lib/alignof.h
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2023-01-18 18:25:25 +0100
committerLudovic Courtès <ludo@gnu.org>2023-01-18 22:50:18 +0100
commitaeb22f486139f457ae7fc44c2d931312aaae52d8 (patch)
tree0fbfe6d421e637553f9bca39f08577c0ddb990e8 /lib/alignof.h
parent4404b553a5a135aee5a606dedea9b6fa25363be4 (diff)
downloadguile-aeb22f486139f457ae7fc44c2d931312aaae52d8.tar.gz
Update Gnulib to v0.1-5703-g356a414e8c and add 'posix_spawn' module.
This is a followup to edfca3b7e5931b5b5a83112e2a9813b068be99c2, which added the 'posix_spawnp' module but not 'posix_spawn'. * m4/gnulib-cache.m4: Add 'posix_spawn' module. * gnulib-local/m4/clock_time.m4.diff: Adjust. * configure.ac: Move 'gl_EARLY' use right after 'AC_PROG_CC'.
Diffstat (limited to 'lib/alignof.h')
-rw-r--r--lib/alignof.h7
1 files changed, 3 insertions, 4 deletions
diff --git a/lib/alignof.h b/lib/alignof.h
index 3f4a54257..2ded1c788 100644
--- a/lib/alignof.h
+++ b/lib/alignof.h
@@ -1,5 +1,5 @@
/* Determine alignment of types.
- Copyright (C) 2003-2004, 2006, 2009-2022 Free Software Foundation, Inc.
+ Copyright (C) 2003-2004, 2006, 2009-2023 Free Software Foundation, Inc.
This file is free software: you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as
@@ -22,15 +22,14 @@
/* alignof_slot (TYPE)
Determine the alignment of a structure slot (field) of a given type,
at compile time. Note that the result depends on the ABI.
- This is the same as alignof (TYPE) and _Alignof (TYPE), defined in
- <stdalign.h> if __alignof_is_defined is 1.
+ This is the same as alignof (TYPE).
Note: The result cannot be used as a value for an 'enum' constant,
due to bugs in HP-UX 10.20 cc and AIX 3.2.5 xlc. */
#if defined __cplusplus
template <class type> struct alignof_helper { char __slot1; type __slot2; };
# define alignof_slot(type) offsetof (alignof_helper<type>, __slot2)
#else
-# define alignof_slot(type) offsetof (struct { char __slot1; type __slot2; }, __slot2)
+# define alignof_slot(type) alignof (type)
#endif
/* alignof_type (TYPE)