[Lldb-commits] [PATCH] D143127: [LLDB] Fix assertion failure by removing `CopyType` in `std::coroutine_handle` pretty printer
Adrian Vogelsgesang via Phabricator via lldb-commits
lldb-commits at lists.llvm.org
Wed Feb 8 10:23:35 PST 2023
This revision was automatically updated to reflect the committed changes.
Closed by commit rG54d4a2550d31: [LLDB] Fix assertion failure by removing `CopyType` in `std::coroutine_handle`… (authored by avogelsgesang).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D143127/new/
https://reviews.llvm.org/D143127
Files:
lldb/source/Plugins/Language/CPlusPlus/Coroutines.cpp
lldb/source/Plugins/Language/CPlusPlus/Coroutines.h
Index: lldb/source/Plugins/Language/CPlusPlus/Coroutines.h
===================================================================
--- lldb/source/Plugins/Language/CPlusPlus/Coroutines.h
+++ lldb/source/Plugins/Language/CPlusPlus/Coroutines.h
@@ -16,8 +16,6 @@
namespace lldb_private {
-class ClangASTImporter;
-
namespace formatters {
/// Summary provider for `std::coroutine_handle<T>` from libc++, libstdc++ and
@@ -50,7 +48,6 @@
lldb::ValueObjectSP m_resume_ptr_sp;
lldb::ValueObjectSP m_destroy_ptr_sp;
lldb::ValueObjectSP m_promise_ptr_sp;
- std::unique_ptr<lldb_private::ClangASTImporter> m_ast_importer;
};
SyntheticChildrenFrontEnd *
Index: lldb/source/Plugins/Language/CPlusPlus/Coroutines.cpp
===================================================================
--- lldb/source/Plugins/Language/CPlusPlus/Coroutines.cpp
+++ lldb/source/Plugins/Language/CPlusPlus/Coroutines.cpp
@@ -8,7 +8,6 @@
#include "Coroutines.h"
-#include "Plugins/ExpressionParser/Clang/ClangASTImporter.h"
#include "Plugins/TypeSystem/Clang/TypeSystemClang.h"
#include "lldb/Symbol/Function.h"
#include "lldb/Symbol/VariableList.h"
@@ -97,8 +96,7 @@
lldb_private::formatters::StdlibCoroutineHandleSyntheticFrontEnd::
StdlibCoroutineHandleSyntheticFrontEnd(lldb::ValueObjectSP valobj_sp)
- : SyntheticChildrenFrontEnd(*valobj_sp),
- m_ast_importer(std::make_unique<ClangASTImporter>()) {
+ : SyntheticChildrenFrontEnd(*valobj_sp) {
if (valobj_sp)
Update();
}
@@ -174,8 +172,7 @@
if (Function *destroy_func =
ExtractDestroyFunction(target_sp, frame_ptr_addr)) {
if (CompilerType inferred_type = InferPromiseType(*destroy_func)) {
- // Copy the type over to the correct `TypeSystemClang` instance
- promise_type = m_ast_importer->CopyType(*ast_ctx, inferred_type);
+ promise_type = inferred_type;
}
}
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D143127.495881.patch
Type: text/x-patch
Size: 1901 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20230208/c673a888/attachment.bin>
More information about the lldb-commits
mailing list