[PATCH] D157331: [clang] Implement C23 <stdckdint.h>
Elliott Hughes via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Aug 16 13:16:37 PDT 2023
enh added inline comments.
================
Comment at: clang/lib/Headers/stdckdint.h:10
+
+#ifndef __STDC_VERSION_STDCKDINT_H__
+#define __STDC_VERSION_STDCKDINT_H__
----------------
i think this should just be `__STDCKDINT_H` to match the other headers' include guards, and then you want a _separate_ #define that defines `__STDC_VERSION_STDCKDINT_H__` (and defines it to the value you're claiming to define it to in the release notes, but don't seem to actually be defining it to here :-) ).
(and maybe add a test that the macro is defined with a value to the tests?)
================
Comment at: clang/lib/Headers/stdckdint.h:18
+#else
+#error "we need a compiler extension for this"
+#endif
----------------
i think this #else should be deleted now? (it will give a misleading error if you build with pre-c23.)
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D157331/new/
https://reviews.llvm.org/D157331
More information about the cfe-commits
mailing list