From 48ea80f9ff86cd7d6aa70cb1d03579c0c87b828b Mon Sep 17 00:00:00 2001 From: Enrico Granata Date: Wed, 24 Oct 2012 20:24:39 +0000 Subject: Reimplementing SBValue/ValueObject.GetValueAsUnsigned() in terms of appropriate calls in Scalar - Making sure Scalar does the right thing when casting signed values to unsigned ones. llvm-svn: 166618 --- lldb/source/Core/ValueObject.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lldb/source/Core/ValueObject.cpp') diff --git a/lldb/source/Core/ValueObject.cpp b/lldb/source/Core/ValueObject.cpp index 86b7e8981d4..f608f85f3cd 100644 --- a/lldb/source/Core/ValueObject.cpp +++ b/lldb/source/Core/ValueObject.cpp @@ -1294,7 +1294,7 @@ ValueObject::GetValueAsUnsigned (uint64_t fail_value, bool *success) { if (success) *success = true; - return scalar.GetRawBits64(fail_value); + return scalar.ULongLong(fail_value); } // fallthrough, otherwise... } @@ -1681,7 +1681,7 @@ ValueObject::SetValueFromCString (const char *value_str, Error& error) Process *process = exe_ctx.GetProcessPtr(); if (process) { - addr_t target_addr = m_value.GetScalar().GetRawBits64(LLDB_INVALID_ADDRESS); + addr_t target_addr = m_value.GetScalar().ULongLong(LLDB_INVALID_ADDRESS); size_t bytes_written = process->WriteScalarToMemory (target_addr, new_scalar, byte_size, -- cgit v1.2.3