summaryrefslogtreecommitdiffstats
path: root/lldb/source/API
diff options
context:
space:
mode:
authorGreg Clayton <gclayton@apple.com>2015-07-08 22:32:23 +0000
committerGreg Clayton <gclayton@apple.com>2015-07-08 22:32:23 +0000
commitddaf6a7259a5f56431ca7889c912601e94d1ce20 (patch)
tree670fc9ed2ab0780f98a2160253921fa4fb6859ab /lldb/source/API
parent4104fe8ae92861d77b40adc78635915fbf6a1470 (diff)
downloadbcm5719-llvm-ddaf6a7259a5f56431ca7889c912601e94d1ce20.tar.gz
bcm5719-llvm-ddaf6a7259a5f56431ca7889c912601e94d1ce20.zip
Make many mangled functions that might demangle a name be allowed to specify a language to use in order to soon support Pascal and Java demangling. Dawn Perchik will take care of making this so.
llvm-svn: 241751
Diffstat (limited to 'lldb/source/API')
-rw-r--r--lldb/source/API/SBBlock.cpp10
-rw-r--r--lldb/source/API/SBFrame.cpp4
-rw-r--r--lldb/source/API/SBFunction.cpp4
-rw-r--r--lldb/source/API/SBSymbol.cpp4
4 files changed, 15 insertions, 7 deletions
diff --git a/lldb/source/API/SBBlock.cpp b/lldb/source/API/SBBlock.cpp
index c8a665f7d6f..fdbbbc04527 100644
--- a/lldb/source/API/SBBlock.cpp
+++ b/lldb/source/API/SBBlock.cpp
@@ -75,7 +75,15 @@ SBBlock::GetInlinedName () const
{
const InlineFunctionInfo* inlined_info = m_opaque_ptr->GetInlinedFunctionInfo ();
if (inlined_info)
- return inlined_info->GetName().AsCString (NULL);
+ {
+ Function *function = m_opaque_ptr->CalculateSymbolContextFunction();
+ LanguageType language;
+ if (function)
+ language = function->GetLanguage();
+ else
+ language = lldb::eLanguageTypeUnknown;
+ return inlined_info->GetName(language).AsCString (NULL);
+ }
}
return NULL;
}
diff --git a/lldb/source/API/SBFrame.cpp b/lldb/source/API/SBFrame.cpp
index 70ee4d44c41..08a5822cb78 100644
--- a/lldb/source/API/SBFrame.cpp
+++ b/lldb/source/API/SBFrame.cpp
@@ -1571,7 +1571,7 @@ SBFrame::GetFunctionName() const
if (inlined_block)
{
const InlineFunctionInfo* inlined_info = inlined_block->GetInlinedFunctionInfo();
- name = inlined_info->GetName().AsCString();
+ name = inlined_info->GetName(sc.function->GetLanguage()).AsCString();
}
}
@@ -1627,7 +1627,7 @@ SBFrame::GetDisplayFunctionName()
if (inlined_block)
{
const InlineFunctionInfo* inlined_info = inlined_block->GetInlinedFunctionInfo();
- name = inlined_info->GetDisplayName().AsCString();
+ name = inlined_info->GetDisplayName(sc.function->GetLanguage()).AsCString();
}
}
diff --git a/lldb/source/API/SBFunction.cpp b/lldb/source/API/SBFunction.cpp
index d57307add03..2ec6072b51e 100644
--- a/lldb/source/API/SBFunction.cpp
+++ b/lldb/source/API/SBFunction.cpp
@@ -60,7 +60,7 @@ SBFunction::GetName() const
{
const char *cstr = NULL;
if (m_opaque_ptr)
- cstr = m_opaque_ptr->GetMangled().GetName().AsCString();
+ cstr = m_opaque_ptr->GetName().AsCString();
Log *log(lldb_private::GetLogIfAllCategoriesSet (LIBLLDB_LOG_API));
if (log)
@@ -80,7 +80,7 @@ SBFunction::GetDisplayName() const
{
const char *cstr = NULL;
if (m_opaque_ptr)
- cstr = m_opaque_ptr->GetMangled().GetDisplayDemangledName().AsCString();
+ cstr = m_opaque_ptr->GetMangled().GetDisplayDemangledName(m_opaque_ptr->GetLanguage()).AsCString();
Log *log(lldb_private::GetLogIfAllCategoriesSet (LIBLLDB_LOG_API));
if (log)
diff --git a/lldb/source/API/SBSymbol.cpp b/lldb/source/API/SBSymbol.cpp
index 171bfd84d0c..22d1e546b5e 100644
--- a/lldb/source/API/SBSymbol.cpp
+++ b/lldb/source/API/SBSymbol.cpp
@@ -63,7 +63,7 @@ SBSymbol::GetName() const
{
const char *name = NULL;
if (m_opaque_ptr)
- name = m_opaque_ptr->GetMangled().GetName().AsCString();
+ name = m_opaque_ptr->GetName().AsCString();
Log *log(lldb_private::GetLogIfAllCategoriesSet (LIBLLDB_LOG_API));
if (log)
@@ -77,7 +77,7 @@ SBSymbol::GetDisplayName() const
{
const char *name = NULL;
if (m_opaque_ptr)
- name = m_opaque_ptr->GetMangled().GetDisplayDemangledName().AsCString();
+ name = m_opaque_ptr->GetMangled().GetDisplayDemangledName(m_opaque_ptr->GetLanguage()).AsCString();
Log *log(lldb_private::GetLogIfAllCategoriesSet (LIBLLDB_LOG_API));
if (log)
OpenPOWER on IntegriCloud