[Lldb-commits] [lldb] [LLDB] Add more helper functions to ValueObject class. (PR #87197)
Alex Langford via lldb-commits
lldb-commits at lists.llvm.org
Mon Apr 1 11:13:23 PDT 2024
================
@@ -2809,6 +2919,243 @@ ValueObjectSP ValueObject::CastPointerType(const char *name, TypeSP &type_sp) {
return valobj_sp;
}
+lldb::addr_t ValueObject::GetLoadAddress() {
+ lldb::addr_t addr_value = LLDB_INVALID_ADDRESS;
+ lldb::TargetSP target_sp = GetTargetSP();
+ if (target_sp) {
----------------
bulbazord wrote:
nit: These lines can be rolled into one
```
if (auto target_sp = GetTargetSP()) {
```
(use of auto is personal preference)
https://github.com/llvm/llvm-project/pull/87197
More information about the lldb-commits
mailing list