From 5d9c157f5e67218f22e34f8212393a929ec2944d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Oliver=20St=C3=B6neberg?= Date: Sat, 25 Feb 2023 00:19:04 +0100 Subject: [PATCH] keywords.cpp: fixed accidental omissions in C++03 keywords / added missing keywords in latest standards (#4825) --- lib/keywords.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/keywords.cpp b/lib/keywords.cpp index aa5e8c360..70fb2f6e3 100644 --- a/lib/keywords.cpp +++ b/lib/keywords.cpp @@ -38,7 +38,7 @@ #endif #define C23_KEYWORDS \ - "alignas", "alignof", "bool", "false", "nullptr", "static_assert", "thread_local", "true", "typeof", "typeof_unqual", \ + "alignas", "alignof", "bool", "constexpr", "false", "nullptr", "static_assert", "thread_local", "true", "typeof", "typeof_unqual", \ "_BitInt", "_Decimal128", "_Decimal32", "_Decimal64" #ifdef __clang__ @@ -86,6 +86,7 @@ static const std::unordered_set c11_keywords = { "float", "for", "friend", "goto", "if", "inline", "int", "long", \ "mutable", "namespace", "new", "not", "not_eq", "operator", \ "or", "or_eq", "private", "protected", "public", "register", "reinterpret_cast", \ + "return", "short", "signed", "sizeof", "static", \ "static_cast", "struct", "switch", "template", "this", "throw", \ "true", "try", "typedef", "typeid", "typename", "union", "unsigned", "using", \ "virtual", "void", "volatile", "wchar_t", "while", "xor", "xor_eq" @@ -95,7 +96,7 @@ static const std::unordered_set c11_keywords = { "noexcept", "nullptr", "static_assert", "thread_local" #define CPP20_KEYWORDS \ - "concept", "consteval", "constinit", "co_await", \ + "char8_t", "concept", "consteval", "constinit", "co_await", \ "co_return", "co_yield", "requires" #ifdef __clang__