Improved the user-friendliness of errors shown by the summary feature in certain areas

Renamed format "signed decimal" to be "decimal". "unsigned decimal" remains unchanged:
 - the name "signed decimal" was interfering with symbol %S (use summary) in summary strings.
   because of the way summary strings are implemented, this did not really lead to a bug, but
   simply to performing more steps than necessary to display a summary. this is fixed.
Documentation improvements (more on synthetic children, some information on filters). This is still a WIP.

llvm-svn: 138384
This commit is contained in:
Enrico Granata
2011-08-23 21:26:09 +00:00
parent bccce81340
commit 88da35f881
7 changed files with 311 additions and 36 deletions

View File

@@ -1021,7 +1021,18 @@ ValueObject::GetPrintableRepresentation(Stream& s,
if (return_value)
s.PutCString(return_value);
else
s.PutCString("<no printable representation>");
{
if (m_error.Fail())
s.Printf("<%s>", m_error.AsCString());
else if (val_obj_display == eDisplaySummary)
s.PutCString("<no summary available>");
else if (val_obj_display == eDisplayValue)
s.PutCString("<no value available>");
else if (val_obj_display == eDisplayLanguageSpecific)
s.PutCString("<not a valid Objective-C object>"); // edit this if we have other runtimes that support a description
else
s.PutCString("<no printable representation>");
}
// we should only return false here if we could not do *anything*
// even if we have an error message as output, that's a success