27 |
#include <assert.h> |
#include <assert.h> |
28 |
#include <string.h> // for memcpy() |
#include <string.h> // for memcpy() |
29 |
#include <stdlib.h> // for atof() |
#include <stdlib.h> // for atof() |
30 |
|
#include <cxxabi.h> |
31 |
|
|
32 |
#include "helper.h" |
#include "helper.h" |
33 |
|
|
128 |
} |
} |
129 |
|
|
130 |
String DataType::asLongDescr() const { |
String DataType::asLongDescr() const { |
|
//TODO: Demangling of C++ raw type names |
|
131 |
String s = m_baseTypeName; |
String s = m_baseTypeName; |
132 |
if (!m_customTypeName.empty()) |
if (!m_customTypeName.empty()) |
133 |
s += " " + m_customTypeName; |
s += " " + customTypeName(true); |
134 |
if (isPointer()) |
if (isPointer()) |
135 |
s += " pointer"; |
s += " pointer"; |
136 |
return s; |
return s; |
137 |
} |
} |
138 |
|
|
139 |
|
String DataType::customTypeName(bool demangle) const { |
140 |
|
if (!demangle) return m_customTypeName; |
141 |
|
int status; |
142 |
|
const char* result = |
143 |
|
abi::__cxa_demangle(m_customTypeName.c_str(), 0, 0, &status); |
144 |
|
return (status == 0) ? result : m_customTypeName; |
145 |
|
} |
146 |
|
|
147 |
// *************** Member *************** |
// *************** Member *************** |
148 |
// * |
// * |
149 |
|
|