summaryrefslogtreecommitdiff
path: root/llvm/tools/llvm-cgdata/llvm-cgdata.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/tools/llvm-cgdata/llvm-cgdata.cpp')
-rw-r--r--llvm/tools/llvm-cgdata/llvm-cgdata.cpp14
1 files changed, 8 insertions, 6 deletions
diff --git a/llvm/tools/llvm-cgdata/llvm-cgdata.cpp b/llvm/tools/llvm-cgdata/llvm-cgdata.cpp
index d33459b194c9..9e3800f5bfbb 100644
--- a/llvm/tools/llvm-cgdata/llvm-cgdata.cpp
+++ b/llvm/tools/llvm-cgdata/llvm-cgdata.cpp
@@ -51,12 +51,13 @@ enum ID {
#undef OPTION
};
-#define PREFIX(NAME, VALUE) \
- static constexpr StringLiteral NAME##_init[] = VALUE; \
- static constexpr ArrayRef<StringLiteral> NAME(NAME##_init, \
- std::size(NAME##_init) - 1);
+#define OPTTABLE_STR_TABLE_CODE
#include "Opts.inc"
-#undef PREFIX
+#undef OPTTABLE_STR_TABLE_CODE
+
+#define OPTTABLE_PREFIXES_TABLE_CODE
+#include "Opts.inc"
+#undef OPTTABLE_PREFIXES_TABLE_CODE
using namespace llvm::opt;
static constexpr opt::OptTable::Info InfoTable[] = {
@@ -67,7 +68,8 @@ static constexpr opt::OptTable::Info InfoTable[] = {
class CGDataOptTable : public opt::GenericOptTable {
public:
- CGDataOptTable() : GenericOptTable(InfoTable) {}
+ CGDataOptTable()
+ : GenericOptTable(OptionStrTable, OptionPrefixesTable, InfoTable) {}
};
} // end anonymous namespace