diff options
author | Ed Maste <emaste@FreeBSD.org> | 2013-11-06 16:48:53 +0000 |
---|---|---|
committer | Ed Maste <emaste@FreeBSD.org> | 2013-11-06 16:48:53 +0000 |
commit | f21a844f60ae6c74fcf1fddca32461acce3c1ee0 (patch) | |
tree | 56d79f94966870db1cecd65a7264510a25fd1cba /include/lldb/DataFormatters/FormatClasses.h | |
parent | 37d22554be9f5a677dad2a95b7ef22fe59c66a8a (diff) |
Notes
Diffstat (limited to 'include/lldb/DataFormatters/FormatClasses.h')
-rw-r--r-- | include/lldb/DataFormatters/FormatClasses.h | 18 |
1 files changed, 8 insertions, 10 deletions
diff --git a/include/lldb/DataFormatters/FormatClasses.h b/include/lldb/DataFormatters/FormatClasses.h index 48a8eda4ad437..6d9a50e8f2c52 100644 --- a/include/lldb/DataFormatters/FormatClasses.h +++ b/include/lldb/DataFormatters/FormatClasses.h @@ -12,7 +12,6 @@ // C Includes #include <stdint.h> -#include <unistd.h> // C++ Includes #include <string> @@ -61,7 +60,7 @@ public: if (type) { m_type.m_type_name.assign(type->GetName().GetCString()); - m_type.m_typeimpl_sp = lldb::TypeImplSP(new TypeImpl(type)); + m_type.m_type_pair.SetType(type); } } @@ -72,7 +71,7 @@ public: if (type.IsValid()) { m_type.m_type_name.assign(type.GetConstTypeName().GetCString()); - m_type.m_typeimpl_sp = lldb::TypeImplSP(new TypeImpl(type)); + m_type.m_type_pair.SetType(type); } } @@ -87,16 +86,16 @@ public: lldb::TypeSP GetTypeSP () { - if (m_type.m_typeimpl_sp && m_type.m_typeimpl_sp->IsValid()) - return m_type.m_typeimpl_sp->GetTypeSP(); + if (m_type.m_type_pair.IsValid()) + return m_type.m_type_pair.GetTypeSP(); return lldb::TypeSP(); } ClangASTType GetClangASTType () { - if (m_type.m_typeimpl_sp && m_type.m_typeimpl_sp->IsValid()) - return m_type.m_typeimpl_sp->GetClangASTType(); + if (m_type.m_type_pair.IsValid()) + return m_type.m_type_pair.GetClangASTType(); return ClangASTType(); } @@ -109,12 +108,11 @@ public: private: bool m_is_regex; // this works better than TypeAndOrName because the latter only wraps a TypeSP - // whereas TypeImplSP can also be backed by a ClangASTType which is more commonly - // used in LLDB. moreover, TypeImplSP is also what is currently backing SBType + // whereas TypePair can also be backed by a ClangASTType struct TypeOrName { std::string m_type_name; - lldb::TypeImplSP m_typeimpl_sp; + TypePair m_type_pair; }; TypeOrName m_type; |