Skip to content

Commit d3019ab

Browse files
committed
Remove the undocumented help subcommand.
This is processed by hand in CommandObjectMultiword, and is undiscoverable, it doesn't work in all cases. Because it is a bare word, it can't really be extended w/o introducing the possibility of collisions as well. If we did want to do something like this we should add a --help flag to CommandObject. That way the feature would be consistent and documented. Differential Revision: https://reviews.llvm.org/D142067 (cherry picked from commit 887240f) (cherry picked from commit 25d95ab)
1 parent 84ec9db commit d3019ab

File tree

2 files changed

+0
-15
lines changed

2 files changed

+0
-15
lines changed

lldb/source/Commands/CommandObjectMultiword.cpp

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -173,11 +173,6 @@ bool CommandObjectMultiword::Execute(const char *args_string,
173173
return result.Succeeded();
174174
}
175175

176-
if (sub_command.equals_insensitive("help")) {
177-
this->CommandObject::GenerateHelpText(result);
178-
return result.Succeeded();
179-
}
180-
181176
if (m_subcommand_dict.empty()) {
182177
result.AppendErrorWithFormat("'%s' does not have any subcommands.\n",
183178
GetCommandName().str().c_str());

lldb/test/API/functionalities/multiword-commands/TestMultiWordCommands.py

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,3 @@ def test_ambiguous_subcommand(self):
1919
@no_debug_info_test
2020
def test_empty_subcommand(self):
2121
self.expect("platform \"\"", error=True, substrs=["Need to specify a non-empty subcommand."])
22-
23-
@no_debug_info_test
24-
def test_help(self):
25-
# <multiword> help brings up help.
26-
self.expect("platform help",
27-
substrs=["Commands to manage and create platforms.",
28-
"Syntax: platform [",
29-
"The following subcommands are supported:",
30-
"connect",
31-
"Select the current platform"])

0 commit comments

Comments
 (0)