Commit 8562dc09 authored by hjk's avatar hjk
Browse files

Debugger: Simplify pointer arithmetic in LLDB dumper



Change-Id: I1b8396014256afc3845ccdae6e740bbf6059bbf3
Reviewed-by: default avatarhjk <hjk121@nokiamail.com>
parent 5be208bc
...@@ -134,11 +134,8 @@ def impl_SBValue__add__(self, offset): ...@@ -134,11 +134,8 @@ def impl_SBValue__add__(self, offset):
itemsize = self.GetType().GetPointeeType().GetByteSize() itemsize = self.GetType().GetPointeeType().GetByteSize()
address = self.GetValueAsUnsigned() + offset * itemsize address = self.GetValueAsUnsigned() + offset * itemsize
address = address & 0xFFFFFFFFFFFFFFFF # Force unsigned address = address & 0xFFFFFFFFFFFFFFFF # Force unsigned
return self.CreateValueFromAddress(None, address,
# We don't have a dumper object self.GetType().GetPointeeType()).AddressOf()
#return createPointerValue(self, address, self.GetType().GetPointeeType())
addr = int(address) & 0xFFFFFFFFFFFFFFFF
return self.CreateValueFromAddress(None, addr, self.GetType().GetPointeeType()).AddressOf()
raise RuntimeError("SBValue.__add__ not implemented: %s" % self.GetType()) raise RuntimeError("SBValue.__add__ not implemented: %s" % self.GetType())
return NotImplemented return NotImplemented
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment