Michael137 created this revision.
Michael137 added a reviewer: aprantl.
Herald added a subscriber: martong.
Herald added a reviewer: a.sidorin.
Herald added a project: All.
Michael137 requested review of this revision.
Herald added a project: LLDB.
Herald added a subscriber: lldb-commits.

The usage of this variable was removed in 
`4f14c17df70916913d71914343dd4f6c709e218d`.

This is no longer used inside this file. Since the call to
`GetPersistentExpressionStateForLanguage` has side-effects I marked this
NFCI. But there is no good reason we need this here.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D157992

Files:
  lldb/source/Plugins/Language/CPlusPlus/BlockPointer.cpp


Index: lldb/source/Plugins/Language/CPlusPlus/BlockPointer.cpp
===================================================================
--- lldb/source/Plugins/Language/CPlusPlus/BlockPointer.cpp
+++ lldb/source/Plugins/Language/CPlusPlus/BlockPointer.cpp
@@ -54,18 +54,6 @@
     if (!clang_ast_context)
       return;
 
-    std::shared_ptr<ClangASTImporter> clang_ast_importer;
-    auto *state = target_sp->GetPersistentExpressionStateForLanguage(
-        lldb::eLanguageTypeC_plus_plus);
-    if (state) {
-      auto *persistent_vars = llvm::cast<ClangPersistentVariables>(state);
-      clang_ast_importer = persistent_vars->GetClangASTImporter();
-    }
-
-    if (!clang_ast_importer) {
-      return;
-    }
-
     const char *const isa_name("__isa");
     const CompilerType isa_type =
         clang_ast_context->GetBasicType(lldb::eBasicTypeObjCClass);


Index: lldb/source/Plugins/Language/CPlusPlus/BlockPointer.cpp
===================================================================
--- lldb/source/Plugins/Language/CPlusPlus/BlockPointer.cpp
+++ lldb/source/Plugins/Language/CPlusPlus/BlockPointer.cpp
@@ -54,18 +54,6 @@
     if (!clang_ast_context)
       return;
 
-    std::shared_ptr<ClangASTImporter> clang_ast_importer;
-    auto *state = target_sp->GetPersistentExpressionStateForLanguage(
-        lldb::eLanguageTypeC_plus_plus);
-    if (state) {
-      auto *persistent_vars = llvm::cast<ClangPersistentVariables>(state);
-      clang_ast_importer = persistent_vars->GetClangASTImporter();
-    }
-
-    if (!clang_ast_importer) {
-      return;
-    }
-
     const char *const isa_name("__isa");
     const CompilerType isa_type =
         clang_ast_context->GetBasicType(lldb::eBasicTypeObjCClass);
_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits
  • [Lldb-commits] [PATCH] D1579... Michael Buch via Phabricator via lldb-commits

Reply via email to