Reimplemented the code that backed the "settings" in lldb. There were many issues with the previous implementation:
- no setting auto completion
- very manual and error prone way of getting/setting variables
- tons of code duplication
- useless instance names for processes, threads
Now settings can easily be defined like option values. The new settings makes use of the "OptionValue" classes so we can re-use the option value code that we use to set settings in command options. No more instances, just "does the right thing".
llvm-svn: 162366
diff --git a/lldb/source/Target/StackFrame.cpp b/lldb/source/Target/StackFrame.cpp
index 6bfddf6..6099ed2 100644
--- a/lldb/source/Target/StackFrame.cpp
+++ b/lldb/source/Target/StackFrame.cpp
@@ -1350,7 +1350,7 @@
{
ExecutionContext exe_ctx (shared_from_this());
bool have_source = false;
- DebuggerInstanceSettings::StopDisassemblyType disasm_display = DebuggerInstanceSettings::eStopDisassemblyTypeNever;
+ Debugger::StopDisassemblyType disasm_display = Debugger::eStopDisassemblyTypeNever;
Target *target = exe_ctx.GetTargetPtr();
if (target)
{
@@ -1378,14 +1378,14 @@
}
switch (disasm_display)
{
- case DebuggerInstanceSettings::eStopDisassemblyTypeNever:
+ case Debugger::eStopDisassemblyTypeNever:
break;
- case DebuggerInstanceSettings::eStopDisassemblyTypeNoSource:
+ case Debugger::eStopDisassemblyTypeNoSource:
if (have_source)
break;
// Fall through to next case
- case DebuggerInstanceSettings::eStopDisassemblyTypeAlways:
+ case Debugger::eStopDisassemblyTypeAlways:
if (target)
{
const uint32_t disasm_lines = debugger.GetDisassemblyLineCount();