schemagen: add C++20 keywords to the C++ keyword allow-list
CI / build (-DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++, clang-arm64, ubuntu-latest-arm64, true) (pull_request) Successful in 54s
CI / pre-commit (pull_request) Successful in 1m5s
CI / build (-DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++, gcc-arm64, ubuntu-latest-arm64, false) (pull_request) Successful in 54s
CI / build (-DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++, clang-amd64, ubuntu-latest-amd64, true) (pull_request) Successful in 1m54s
CI / build (-DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++, gcc-amd64, ubuntu-latest-amd64, false) (pull_request) Successful in 1m33s
CI / build (-DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++, clang-arm64, ubuntu-latest-arm64, true) (pull_request) Successful in 54s
CI / pre-commit (pull_request) Successful in 1m5s
CI / build (-DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++, gcc-arm64, ubuntu-latest-arm64, false) (pull_request) Successful in 54s
CI / build (-DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++, clang-amd64, ubuntu-latest-amd64, true) (pull_request) Successful in 1m54s
CI / build (-DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++, gcc-amd64, ubuntu-latest-amd64, false) (pull_request) Successful in 1m33s
Add concept, consteval, constinit, co_await, co_return, co_yield, requires, module, and import to _CPP_KEYWORDS so property names that happen to be C++20 keywords get sanitized with a trailing underscore. Closes #18
This commit is contained in:
@@ -133,9 +133,15 @@ _CPP_KEYWORDS = {
|
||||
"catch",
|
||||
"char",
|
||||
"class",
|
||||
"concept",
|
||||
"const",
|
||||
"consteval",
|
||||
"constinit",
|
||||
"constexpr",
|
||||
"continue",
|
||||
"co_await",
|
||||
"co_return",
|
||||
"co_yield",
|
||||
"decltype",
|
||||
"default",
|
||||
"delete",
|
||||
@@ -152,9 +158,11 @@ _CPP_KEYWORDS = {
|
||||
"friend",
|
||||
"goto",
|
||||
"if",
|
||||
"import",
|
||||
"inline",
|
||||
"int",
|
||||
"long",
|
||||
"module",
|
||||
"namespace",
|
||||
"new",
|
||||
"not",
|
||||
@@ -166,6 +174,7 @@ _CPP_KEYWORDS = {
|
||||
"public",
|
||||
"register",
|
||||
"return",
|
||||
"requires",
|
||||
"short",
|
||||
"signed",
|
||||
"sizeof",
|
||||
|
||||
Reference in New Issue
Block a user