[Lldb-commits] [lldb] r148494 - /lldb/trunk/source/Core/ValueObject.cpp
Jim Ingham
jingham at apple.com
Thu Jan 19 13:10:56 PST 2012
Author: jingham
Date: Thu Jan 19 15:10:56 2012
New Revision: 148494
URL: http://llvm.org/viewvc/llvm-project?rev=148494&view=rev
Log:
ValueObjectRegister type value objects should obey the format in ValueAsCString.
<rdar://problem/10719481>
Modified:
lldb/trunk/source/Core/ValueObject.cpp
Modified: lldb/trunk/source/Core/ValueObject.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Core/ValueObject.cpp?rev=148494&r1=148493&r2=148494&view=diff
==============================================================================
--- lldb/trunk/source/Core/ValueObject.cpp (original)
+++ lldb/trunk/source/Core/ValueObject.cpp Thu Jan 19 15:10:56 2012
@@ -1080,8 +1080,17 @@
const RegisterInfo *reg_info = m_value.GetRegisterInfo();
if (reg_info)
{
+ lldb::Format my_format = GetFormat();
+ if (m_format == lldb::eFormatDefault)
+ {
+ if (m_last_value_format)
+ my_format = m_last_value_format->GetFormat();
+ else
+ my_format = reg_info->format;
+ }
+
StreamString reg_sstr;
- m_data.Dump(®_sstr, 0, reg_info->format, reg_info->byte_size, 1, UINT32_MAX, LLDB_INVALID_ADDRESS, 0, 0, GetExecutionContextScope());
+ m_data.Dump(®_sstr, 0, my_format, reg_info->byte_size, 1, UINT32_MAX, LLDB_INVALID_ADDRESS, 0, 0, GetExecutionContextScope());
m_value_str.swap(reg_sstr.GetString());
}
}
More information about the lldb-commits
mailing list