This patch separates the generic portion of ClangExpressionVariable, which

stores information about a variable that different parts of LLDB use, from the
compiler-specific portion that only the expression parser cares about.

http://reviews.llvm.org/D12602

llvm-svn: 246871
This commit is contained in:
Sean Callanan
2015-09-04 20:49:51 +00:00
parent a729204103
commit bc8ac34e61
30 changed files with 509 additions and 498 deletions

View File

@@ -9,3 +9,24 @@
#include "lldb/Expression/ExpressionVariable.h"
using namespace lldb_private;
ExpressionVariable::~ExpressionVariable()
{
}
uint8_t *
ExpressionVariable::GetValueBytes()
{
const size_t byte_size = m_frozen_sp->GetByteSize();
if (byte_size > 0)
{
if (m_frozen_sp->GetDataExtractor().GetByteSize() < byte_size)
{
m_frozen_sp->GetValue().ResizeData(byte_size);
m_frozen_sp->GetValue().GetData (m_frozen_sp->GetDataExtractor());
}
return const_cast<uint8_t *>(m_frozen_sp->GetDataExtractor().GetDataStart());
}
return NULL;
}