summaryrefslogtreecommitdiffstats
path: root/lldb/source/Commands/CommandObjectSettings.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lldb/source/Commands/CommandObjectSettings.cpp')
-rw-r--r--lldb/source/Commands/CommandObjectSettings.cpp21
1 files changed, 9 insertions, 12 deletions
diff --git a/lldb/source/Commands/CommandObjectSettings.cpp b/lldb/source/Commands/CommandObjectSettings.cpp
index 4d545d79382..f1420a23dbe 100644
--- a/lldb/source/Commands/CommandObjectSettings.cpp
+++ b/lldb/source/Commands/CommandObjectSettings.cpp
@@ -27,6 +27,12 @@ using namespace lldb_private;
// CommandObjectSettingsSet
//-------------------------------------------------------------------------
+static OptionDefinition g_settings_set_options[] = {
+ // clang-format off
+ { LLDB_OPT_SET_2, false, "global", 'g', OptionParser::eNoArgument, nullptr, nullptr, 0, eArgTypeNone, "Apply the new value to the global default value." }
+ // clang-format on
+};
+
class CommandObjectSettingsSet : public CommandObjectRaw {
public:
CommandObjectSettingsSet(CommandInterpreter &interpreter)
@@ -118,11 +124,9 @@ insert-before or insert-after.");
m_global = false;
}
- const OptionDefinition *GetDefinitions() override { return g_option_table; }
-
- // Options table: Required for subclasses of Options.
-
- static OptionDefinition g_option_table[];
+ llvm::ArrayRef<OptionDefinition> GetDefinitions() override {
+ return g_settings_set_options;
+ }
// Instance variables to hold the values for command options.
@@ -242,13 +246,6 @@ private:
CommandOptions m_options;
};
-OptionDefinition CommandObjectSettingsSet::CommandOptions::g_option_table[] = {
- // clang-format off
- {LLDB_OPT_SET_2, false, "global", 'g', OptionParser::eNoArgument, nullptr, nullptr, 0, eArgTypeNone, "Apply the new value to the global default value."},
- {0, false, nullptr, 0, 0, nullptr, nullptr, 0, eArgTypeNone, nullptr}
- // clang-format on
-};
-
//-------------------------------------------------------------------------
// CommandObjectSettingsShow -- Show current values
//-------------------------------------------------------------------------
OpenPOWER on IntegriCloud