[Lldb-commits] [PATCH] D95992: Print the "no plugin" warning only when there is no plugin
    Adrian Prantl via Phabricator via lldb-commits 
    lldb-commits at lists.llvm.org
       
    Wed Feb  3 18:21:04 PST 2021
    
    
  
aprantl created this revision.
aprantl added reviewers: JDevlieghere, jingham.
aprantl requested review of this revision.
Print the "no plugin" warning only when there is no plugin and not when the typesystem failed to initialize.
rdar://72562341
https://reviews.llvm.org/D95992
Files:
  lldb/source/Target/Process.cpp
Index: lldb/source/Target/Process.cpp
===================================================================
--- lldb/source/Target/Process.cpp
+++ lldb/source/Target/Process.cpp
@@ -5684,9 +5684,9 @@
   LanguageType language = sc.GetLanguage();
   if (language == eLanguageTypeUnknown)
     return;
-  auto type_system_or_err = sc.module_sp->GetTypeSystemForLanguage(language);
-  if (auto err = type_system_or_err.takeError()) {
-    llvm::consumeError(std::move(err));
+  LanguageSet plugins =
+      PluginManager::GetAllTypeSystemSupportedLanguagesForTypes();
+  if (!plugins[language]) {
     PrintWarning(Process::Warnings::eWarningsUnsupportedLanguage,
                  sc.module_sp.get(),
                  "This version of LLDB has no plugin for the %s language. "
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D95992.321287.patch
Type: text/x-patch
Size: 773 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20210204/090c478a/attachment-0001.bin>
    
    
More information about the lldb-commits
mailing list