Fix error message when attempting to generate invalid alias.



git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@118036 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/Commands/CommandObjectCommands.cpp b/source/Commands/CommandObjectCommands.cpp
index 8bbe914..ea4ae03 100644
--- a/source/Commands/CommandObjectCommands.cpp
+++ b/source/Commands/CommandObjectCommands.cpp
@@ -298,8 +298,9 @@
                          }
                          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 @@
 
                  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)))
                      {