diff options
author | Caroline Tice <ctice@apple.com> | 2010-11-02 19:00:04 +0000 |
---|---|---|
committer | Caroline Tice <ctice@apple.com> | 2010-11-02 19:00:04 +0000 |
commit | f415eeb4d323ee5ca4a1be196e148e23a758d039 (patch) | |
tree | 12cdc5e5a2ca2ee8a872f92a712d4286d6e4275c /lldb/source/Commands/CommandObjectCommands.cpp | |
parent | d79d31204ce3cb93c877fbaca8f96ae51316daa7 (diff) | |
download | bcm5719-llvm-f415eeb4d323ee5ca4a1be196e148e23a758d039.tar.gz bcm5719-llvm-f415eeb4d323ee5ca4a1be196e148e23a758d039.zip |
Fix error message when attempting to generate invalid alias.
llvm-svn: 118036
Diffstat (limited to 'lldb/source/Commands/CommandObjectCommands.cpp')
-rw-r--r-- | lldb/source/Commands/CommandObjectCommands.cpp | 17 |
1 files changed, 3 insertions, 14 deletions
diff --git a/lldb/source/Commands/CommandObjectCommands.cpp b/lldb/source/Commands/CommandObjectCommands.cpp index 8bbe914f01d..ea4ae03939b 100644 --- a/lldb/source/Commands/CommandObjectCommands.cpp +++ b/lldb/source/Commands/CommandObjectCommands.cpp @@ -298,8 +298,9 @@ public: } else { - result.AppendErrorWithFormat ("Error occurred while attempting to look up command '%s %s'.\n", - alias_command.c_str(), sub_command.c_str()); + result.AppendErrorWithFormat("'%s' is not a valid sub-command of '%s'. " + "Unable to create alias.\n", + sub_command.c_str(), actual_command.c_str()); result.SetStatus (eReturnStatusFailed); return false; } @@ -310,18 +311,6 @@ public: if (args.GetArgumentCount () > 0) { - //if ((!use_subcommand && (cmd_obj->WantsRawCommandString())) - // || (use_subcommand && (sub_cmd_obj->WantsRawCommandString()))) - //{ - // result.AppendErrorWithFormat ("'%s' cannot be aliased with any options or arguments.\n", - // (use_subcommand ? sub_cmd_obj->GetCommandName() - // : cmd_obj->GetCommandName())); - // result.SetStatus (eReturnStatusFailed); - // return false; - //} - - // options or arguments have been passed to the alias command, and must be - // verified & processed here. if ((!use_subcommand && (cmd_obj->GetOptions() != NULL)) || (use_subcommand && (sub_cmd_obj->GetOptions() != NULL))) { |