[clang] [Clang] support storage-class specifiers in C23 compound literals (PR #212559)
Oleksandr Tarasiuk via cfe-commits
cfe-commits at lists.llvm.org
Wed Jul 29 03:26:09 PDT 2026
================
@@ -2656,6 +2656,59 @@ bool Parser::tryParseOpenMPArrayShapingCastPart() {
return !ErrorFound;
}
+bool Parser::isCompoundLiteralStorageClassSpecifier(const Token &Tok) const {
+ if (!getLangOpts().C23)
+ return false;
+ switch (Tok.getKind()) {
+ case tok::kw_constexpr:
----------------
a-tarasyuk wrote:
I've changed this to parse all standard storage-class specifiers and reject those that aren't supported, like `auto`, `typedef`, etc.
https://github.com/llvm/llvm-project/pull/212559
More information about the cfe-commits
mailing list