diff --git a/lldb/source/Commands/CommandObjectSettings.cpp b/lldb/source/Commands/CommandObjectSettings.cpp --- a/lldb/source/Commands/CommandObjectSettings.cpp +++ b/lldb/source/Commands/CommandObjectSettings.cpp @@ -154,7 +154,7 @@ return; // Complete option name - if (arg[0] != '-') + if (arg[0] == '-') return; // Complete setting value diff --git a/lldb/test/API/functionalities/completion/TestCompletion.py b/lldb/test/API/functionalities/completion/TestCompletion.py --- a/lldb/test/API/functionalities/completion/TestCompletion.py +++ b/lldb/test/API/functionalities/completion/TestCompletion.py @@ -405,6 +405,12 @@ ['target.process.thread.step-avoid-regexp', 'target.process.thread.trace-thread']) + def test_settings_set_stop_disassembly_display_value(self): + """Test that 'settins set stop-disassembly-display ' completes to [ + 'never', 'always', 'no-debuginfo', 'no-source'].""" + self.complete_from_to('settings set stop-disassembly-display ', + ['never', 'always', 'no-debuginfo', 'no-source']) + def test_thread_plan_discard(self): self.build() (_, _, thread, _) = lldbutil.run_to_source_breakpoint(self,