summaryrefslogtreecommitdiffstats
path: root/lldb/source/Target/LanguageRuntime.cpp
diff options
context:
space:
mode:
authorJim Ingham <jingham@apple.com>2015-04-17 00:44:36 +0000
committerJim Ingham <jingham@apple.com>2015-04-17 00:44:36 +0000
commitde50d36ab39b9d591bae6562f76a6e0c3169e84b (patch)
tree651b53b75d5680d7cd9cae946a904595eb6aeaf2 /lldb/source/Target/LanguageRuntime.cpp
parenta09bcd0632ce7b15cfb4788d15e4df54034cf284 (diff)
downloadbcm5719-llvm-de50d36ab39b9d591bae6562f76a6e0c3169e84b.tar.gz
bcm5719-llvm-de50d36ab39b9d591bae6562f76a6e0c3169e84b.zip
Fix "help language", the languages printer was assuming the
eLanguageType numbers would be sequential, but vendor types are not and the printer went crazy. llvm-svn: 235153
Diffstat (limited to 'lldb/source/Target/LanguageRuntime.cpp')
-rw-r--r--lldb/source/Target/LanguageRuntime.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/lldb/source/Target/LanguageRuntime.cpp b/lldb/source/Target/LanguageRuntime.cpp
index 50e110c6544..b45af84702b 100644
--- a/lldb/source/Target/LanguageRuntime.cpp
+++ b/lldb/source/Target/LanguageRuntime.cpp
@@ -369,6 +369,15 @@ LanguageRuntime::GetNameForLanguageType (LanguageType language)
return language_names[eLanguageTypeUnknown].name;
}
+void
+LanguageRuntime::PrintAllLanguages (Stream &s, const char *prefix, const char *suffix)
+{
+ for (uint32_t i = 1; i < num_languages; i++)
+ {
+ s.Printf("%s%s%s", prefix, language_names[i].name, suffix);
+ }
+}
+
bool
LanguageRuntime::LanguageIsCPlusPlus (LanguageType language)
{
OpenPOWER on IntegriCloud