summaryrefslogtreecommitdiffstats
path: root/build/has
diff options
context:
space:
mode:
authorTavian Barnes <tavianator@tavianator.com>2025-01-07 11:15:25 -0500
committerTavian Barnes <tavianator@tavianator.com>2025-01-07 11:15:25 -0500
commitc6d6720c3026efb74092c021a06f8f2c6d36fb67 (patch)
treee57d63d36eb0629d4d5fcc092855a6a582a93d1d /build/has
parent44dc45316dff757eafbcd1e09f4c52a285ff9738 (diff)
downloadbfs-c6d6720c3026efb74092c021a06f8f2c6d36fb67.tar.xz
build: Check for compound literal storage-class support
This lets us use them on GCC >= 13, even before C23.
Diffstat (limited to 'build/has')
-rw-r--r--build/has/compound-literal-storage.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/build/has/compound-literal-storage.c b/build/has/compound-literal-storage.c
new file mode 100644
index 0000000..e2281e1
--- /dev/null
+++ b/build/has/compound-literal-storage.c
@@ -0,0 +1,6 @@
+// Copyright © Tavian Barnes <tavianator@tavianator.com>
+// SPDX-License-Identifier: 0BSD
+
+int main(void) {
+ return (static int){0};
+}