summaryrefslogtreecommitdiffstats
path: root/lldb/source/Commands/CommandObjectApropos.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lldb/source/Commands/CommandObjectApropos.cpp')
-rw-r--r--lldb/source/Commands/CommandObjectApropos.cpp21
1 files changed, 14 insertions, 7 deletions
diff --git a/lldb/source/Commands/CommandObjectApropos.cpp b/lldb/source/Commands/CommandObjectApropos.cpp
index bdb70df1a32..0f10b3ec780 100644
--- a/lldb/source/Commands/CommandObjectApropos.cpp
+++ b/lldb/source/Commands/CommandObjectApropos.cpp
@@ -40,14 +40,18 @@ CommandObjectApropos::~CommandObjectApropos()
bool
-CommandObjectApropos::Execute (Args &command, CommandContext *context, CommandInterpreter *interpreter,
- CommandReturnObject &result)
+CommandObjectApropos::Execute
+(
+ CommandInterpreter &interpreter,
+ Args& args,
+ CommandReturnObject &result
+)
{
- const int argc = command.GetArgumentCount ();
+ const int argc = args.GetArgumentCount ();
if (argc == 1)
{
- const char *search_word = command.GetArgumentAtIndex(0);
+ const char *search_word = args.GetArgumentAtIndex(0);
if ((search_word != NULL)
&& (strlen (search_word) > 0))
{
@@ -55,7 +59,7 @@ CommandObjectApropos::Execute (Args &command, CommandContext *context, CommandIn
// is private.
StringList commands_found;
StringList commands_help;
- interpreter->FindCommandsForApropos (search_word, commands_found, commands_help);
+ interpreter.FindCommandsForApropos (search_word, commands_found, commands_help);
if (commands_found.GetSize() == 0)
{
result.AppendMessageWithFormat ("No commands found pertaining to '%s'.", search_word);
@@ -74,8 +78,11 @@ CommandObjectApropos::Execute (Args &command, CommandContext *context, CommandIn
}
for (int i = 0; i < commands_found.GetSize(); ++i)
- interpreter->OutputFormattedHelpText (result.GetOutputStream(), commands_found.GetStringAtIndex(i),
- "--", commands_help.GetStringAtIndex(i), max_len);
+ interpreter.OutputFormattedHelpText (result.GetOutputStream(),
+ commands_found.GetStringAtIndex(i),
+ "--", commands_help.
+ GetStringAtIndex(i),
+ max_len);
}
result.SetStatus (eReturnStatusSuccessFinishNoResult);
OpenPOWER on IntegriCloud