1
0
mirror of https://git.savannah.gnu.org/git/gnulib.git synced 2025-08-16 01:22:18 +03:00
Commit Graph

14 Commits

Author SHA1 Message Date
Paul Eggert
775dbeeb11 stdalign: correct mistake in alignof doc
Problem reported by Joseph Myers in:
https://gcc.gnu.org/ml/gcc-patches/2016-09/msg00340.html
* doc/posix-headers/stdalign.texi: Do not imply that C11 prohibits
alignof(S) where S is a structure containing a flexible array
member.  The Gnulib substitute does not support this, but C11 does.
2016-09-06 14:26:43 -07:00
Paul Eggert
956fa543b1 stdalign: port to Sun C 5.9
* doc/posix-headers/stdalign.texi: Document this.
* lib/stdalign.in.h (_Alignas): Sun C 5.9 also supports
__attribute__ ((__aligned__ (...))).
2015-10-25 01:11:20 -07:00
Paul Eggert
04dee58e17 fts: port to C11 alignof
* doc/posix-headers/stdalign.texi (stdalign.h):
Document the C11 restriction.
* lib/fts.c: Include stddef.h, for max_align_t.
(fts_alloc): Align using max_align_t, not FTSENT.
* modules/fts (Depends-on): Add stddef.
2015-10-18 10:04:12 -07:00
Paul Eggert
076ac82d1d stdalign: doc fix
* doc/posix-headers/stdalign.texi (stdalign.h):
Gnulib doesn't support '_Alignof expr'.
2013-03-30 10:21:41 -07:00
Paul Eggert
76b501132e stdalign: port to stricter ISO C11
ISO C11 says that _Alignof's operand must be a parenthesized type.
Problem reported by Eli Zaretskii in
<http://lists.gnu.org/archive/html/emacs-devel/2013-03/msg00960.html>.
* doc/posix-headers/stdalign.texi (stdalign.h): Document this.
* m4/stdalign.m4 (gl_STDALIGN_H): Don't use _Alignof (expr).
2013-03-29 19:48:38 -07:00
Paul Eggert
be29134ddd stdalign: @samp -> @code in doc for consistency 2012-02-24 14:26:59 -08:00
Bruno Haible
1d99767ae5 stdalign: Document the last change.
* doc/posix-headers/stdalign.texi: Mention GCC bug 52023.
2012-01-27 21:20:39 +01:00
Paul Eggert
eec8a69158 doc: C11 and C++11 are now official 2012-01-06 09:56:38 -08:00
Paul Eggert
772abedb9a stdalign: port to Clang 3.0
Problem reported by Simon Josefsson in
<http://lists.gnu.org/archive/html/bug-gnulib/2011-12/msg00005.html>.
* doc/posix-headers/stdalign.texi (stdalign.h): Mention Clang 3.0,
which has <stdalign.h> but which does not define alignof.
* m4/stdalign.m4 (gl_STDALIGN_H): Check for Clang 3.0's problem.
2011-12-02 01:35:51 -08:00
Paul Eggert
d7f63fea42 * doc/posix-headers/stdalign.texi (stdalign.h): Mention Sun review ID. 2011-11-06 13:32:59 -08:00
Paul Eggert
086fbef22c * tests/test-stdalign.c (TEST_ALIGNMENT): Shrink back to 8.
mingw supports alignments only up to 8 (!).  Reported by Bruno Haible in
<http://lists.gnu.org/archive/html/bug-gnulib/2011-11/msg00006.html>.
* doc/posix-headers/stdalign.texi (stdalign.h): Document this.
2011-11-01 08:23:36 -07:00
Paul Eggert
4e647944bd stdalign: port better to MSVC and to Sun C 5.11
I think these problems were reported by Bruno Haible, in email
that I've unfortunately misplaced.
* doc/posix-headers/stdalign.texi (stdalign.h): Document more
shortcomings of MSVC and of Sun C 5.11.
* lib/stdalign.in.h (_Alignas): Omit bogus extra parenthesis
around __declspec arg.
* modules/stdalign-tests (Files): Add tests/macros.h.
* tests/test-stdalign.c: Do not include <stdlib.h>; no longer needed.
Include macros.h, for ASSERT.
(DECLARE_ALIGNED): Remove.
(TEST_ALIGNMENT): Define to 16 if alignment is supported (more likely
to catch bug), and to 1 if not (simplifies the rest of the code).
(CHECK_STATIC): Always declare the alignment test vars; that's simpler.
(CHECK_AUTO): Remove.
(CHECK_ALIGNED): Check only the alignment of the static vars,
since auto var alignment isn't supported by Sun C 5.11.
(CHECK_TYPES): Remove.  All uses replaced by inline code, so that
ASSERT failures are easier to diagnose.
2011-10-31 22:37:30 -07:00
Paul Eggert
610ca128a2 Adjust to Bruno's comments. 2011-10-27 13:05:43 -07:00
Paul Eggert
6dc2ffa573 stdalign: new module
* doc/posix-headers/stdalign.texi, lib/stdalign.in.h, m4/stdalign.m4:
* modules/stdalign: New files.
* MODULES.html.sh (c1x_core_properties): Add stdalign.
* doc/gnulib.texi (Header File Substitutes): Add stdalign.
2011-10-27 13:05:41 -07:00