summaryrefslogtreecommitdiffstats
path: root/lldb/source/API/SBValue.cpp
diff options
context:
space:
mode:
authorBruce Mitchener <bruce.mitchener@gmail.com>2015-02-26 23:55:39 +0000
committerBruce Mitchener <bruce.mitchener@gmail.com>2015-02-26 23:55:39 +0000
commit11d86362ae6e8eb16bbd193a8f6c87f29ae5252b (patch)
tree06d5554064e9130585727fc786c08513ec55f1b8 /lldb/source/API/SBValue.cpp
parent4491d0d337a42f34cf5f51a7324ee6e8af8eb5c2 (diff)
downloadbcm5719-llvm-11d86362ae6e8eb16bbd193a8f6c87f29ae5252b.tar.gz
bcm5719-llvm-11d86362ae6e8eb16bbd193a8f6c87f29ae5252b.zip
Remove duplicated code for synthetic array members.
Summary: The code for GetSyntheticArrayMemberFromPointer and GetSyntheticArrayMemberFromArray was identical, so just collapse the the methods into one. Reviewers: granata.enrico, clayborg Reviewed By: clayborg Subscribers: lldb-commits Differential Revision: http://reviews.llvm.org/D7911 llvm-svn: 230708
Diffstat (limited to 'lldb/source/API/SBValue.cpp')
-rw-r--r--lldb/source/API/SBValue.cpp9
1 files changed, 1 insertions, 8 deletions
diff --git a/lldb/source/API/SBValue.cpp b/lldb/source/API/SBValue.cpp
index e383f4ca919..1b29f6c8f7e 100644
--- a/lldb/source/API/SBValue.cpp
+++ b/lldb/source/API/SBValue.cpp
@@ -969,14 +969,7 @@ SBValue::GetChildAtIndex (uint32_t idx, lldb::DynamicValueType use_dynamic, bool
child_sp = value_sp->GetChildAtIndex (idx, can_create);
if (can_create_synthetic && !child_sp)
{
- if (value_sp->IsPointerType())
- {
- child_sp = value_sp->GetSyntheticArrayMemberFromPointer(idx, can_create);
- }
- else if (value_sp->IsArrayType())
- {
- child_sp = value_sp->GetSyntheticArrayMemberFromArray(idx, can_create);
- }
+ child_sp = value_sp->GetSyntheticArrayMember(idx, can_create);
}
}
OpenPOWER on IntegriCloud