summaryrefslogtreecommitdiffstats
path: root/lldb/source/Core/Debugger.cpp
diff options
context:
space:
mode:
authorJim Ingham <jingham@apple.com>2011-12-22 19:12:40 +0000
committerJim Ingham <jingham@apple.com>2011-12-22 19:12:40 +0000
commitef651600167a47060e4b19bdb788a0d1649671b8 (patch)
treeaabe5d4cfbeb06df5596ec5731c1d5e5f1485760 /lldb/source/Core/Debugger.cpp
parent6901c0de675f3c264d496cdd75ac08fd21109305 (diff)
downloadbcm5719-llvm-ef651600167a47060e4b19bdb788a0d1649671b8.tar.gz
bcm5719-llvm-ef651600167a47060e4b19bdb788a0d1649671b8.zip
Improve the x86_64 return value decoder to handle most structure returns.
Switch from GetReturnValue, which was hardly ever used, to GetReturnValueObject which is much more convenient. Return the "return value object" as a persistent variable if requested. llvm-svn: 147157
Diffstat (limited to 'lldb/source/Core/Debugger.cpp')
-rw-r--r--lldb/source/Core/Debugger.cpp11
1 files changed, 4 insertions, 7 deletions
diff --git a/lldb/source/Core/Debugger.cpp b/lldb/source/Core/Debugger.cpp
index e33e9412c91..f460fa1afcf 100644
--- a/lldb/source/Core/Debugger.cpp
+++ b/lldb/source/Core/Debugger.cpp
@@ -1709,12 +1709,9 @@ Debugger::FormatPrompt
ValueObjectSP return_valobj_sp = StopInfo::GetReturnValueObject (stop_info_sp);
if (return_valobj_sp)
{
- cstr = return_valobj_sp->GetValueAsCString ();
- if (cstr && cstr[0])
- {
- s.PutCString(cstr);
- var_success = true;
- }
+ ValueObject::DumpValueObjectOptions dump_options;
+ ValueObject::DumpValueObject (s, return_valobj_sp.get(), dump_options);
+ var_success = true;
}
}
}
@@ -2579,7 +2576,7 @@ Debugger::SettingsController::global_settings_table[] =
MODULE_WITH_FUNC\
FILE_AND_LINE\
"{, stop reason = ${thread.stop-reason}}"\
- "{, return value = ${thread.return-value}}"\
+ "{\\nReturn value: ${thread.return-value}}"\
"\\n"
//#define DEFAULT_THREAD_FORMAT "thread #${thread.index}: tid = ${thread.id}"\
OpenPOWER on IntegriCloud