-
Notifications
You must be signed in to change notification settings - Fork 15.4k
[lldb] Remove CommandReturnObject::AppendRawError #171517
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -3708,7 +3708,7 @@ CommandInterpreter::ResolveCommandImpl(std::string &command_line, | |
| for (uint32_t i = 0; i < num_matches; ++i) { | ||
| error_msg.Printf("\t%s\n", matches.GetStringAtIndex(i)); | ||
| } | ||
| result.AppendRawError(error_msg.GetString()); | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Do you also want to uncapitalize Ambiguous on line 3705 above as well.
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Also remove the pointless \n at the end. |
||
| result.AppendError(error_msg.GetString()); | ||
| } | ||
| } else { | ||
| // We didn't have only one match, otherwise we wouldn't get here. | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -24,7 +24,7 @@ def test_ambiguous_command_with_alias(self): | |
| self.assertFalse(result.Succeeded()) | ||
| self.assertEqual( | ||
| result.GetError(), | ||
| "Ambiguous command 'co'. Possible matches:\n\tcommand\n\tcontinue\n\tcorefile\n", | ||
| "error: Ambiguous command 'co'. Possible matches:\n\tcommand\n\tcontinue\n\tcorefile\n", | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This should be "error: ambiguous..." right?
Member
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yup, already put up #171519. I'll do the same for the newline. |
||
| ) | ||
|
|
||
| command_interpreter.HandleCommand("command unalias continue", result) | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
AppendError ends up trimming this "\n" from the end of the string, then putting another on on. So there's no reason to keep the
append("\n")here.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
#171531