diff options
| author | Sean Kurtz <seankurtz75@gmail.com> | 2026-11-25 00:17:57 -0600 |
|---|---|---|
| committer | Sean Kurtz <seankurtz75@gmail.com> | 2026-11-25 00:17:57 -0600 |
| commit | 122dd54f6d915240cd5327d08f9b36e243983956 (patch) | |
| tree | 2217d81fbf0f5e12869b044522177b90fd4fde9c /web/layouts/partials/git@git.abendless.com:/srv/git | |
| parent | ef023766c6c62b3f1b5bd002a061512a55531e46 (diff) | |
| download | zash-122dd54f6d915240cd5327d08f9b36e243983956.tar.gz | |
C23: compile as C23 and use its spelling
The z/OS toolchain would not take C23 when this was first written; IBM
Open XL C/C++ 2.2 does (clang 21.1, __STDC_VERSION__ 202311), and so
does the clang on Linux. -std=c23 in the Makefile, and the standard
attributes in place of the ones that were macros:
_Noreturn -> [[noreturn]] (on declarations and definitions)
_Static_assert -> static_assert
_Alignas -> alignas
NODISCARD -> [[nodiscard]]
FALLTHROUGH -> [[fallthrough]]
PRINTFLIKE and UNREACHABLE() stay macros: [[gnu::format]] and
[[gnu::unreachable]] are vendor attributes, and the standard has no
[[format]] or [[unreachable]] for a header-only project yet.
Standard-library additions newer than the libc of either system
(<stdbit.h>, <stdckdint.h>) are not used, so gcc -std=c2x still builds
the tree warning-free. The suite, ASan/UBSan and the z/OS lint pass as
before; linux/i-dscomplete remains the one local failure it was on
main.
Diffstat (limited to 'web/layouts/partials/git@git.abendless.com:/srv/git')
0 files changed, 0 insertions, 0 deletions
