[Lldb-commits] [lldb] [lldb][NFC] Move helpers to import record layout into ClangASTImporter (PR #83291)
via lldb-commits
lldb-commits at lists.llvm.org
Thu Feb 29 13:23:49 PST 2024
github-actions[bot] wrote:
<!--LLVM CODE FORMAT COMMENT: {clang-format}-->
:warning: C/C++ code formatter, clang-format found issues in your code. :warning:
<details>
<summary>
You can test this locally with the following command:
</summary>
``````````bash
git-clang-format --diff 07d8a457ad8bb9a14974b9cb47072746c7f5e489 391e87f97ee17281ef4a91b3cc1ca6cec8626058 -- lldb/source/Plugins/ExpressionParser/Clang/ClangASTImporter.cpp lldb/source/Plugins/ExpressionParser/Clang/ClangASTImporter.h lldb/source/Plugins/ExpressionParser/Clang/ClangASTSource.cpp lldb/source/Plugins/ExpressionParser/Clang/ClangASTSource.h
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/lldb/source/Plugins/ExpressionParser/Clang/ClangASTImporter.cpp b/lldb/source/Plugins/ExpressionParser/Clang/ClangASTImporter.cpp
index be39e4c5ed..99d210c347 100644
--- a/lldb/source/Plugins/ExpressionParser/Clang/ClangASTImporter.cpp
+++ b/lldb/source/Plugins/ExpressionParser/Clang/ClangASTImporter.cpp
@@ -535,8 +535,9 @@ bool ClangASTImporter::CompleteType(const CompilerType &compiler_type) {
/// \param[in] source_map A map from decls to integral offests. These will
/// be copied into \ref destination_map.
/// \param[in,out] importer Used to import decls into \ref dest_ctx.
-///
-/// \returns On success, will return 'true' and the offsets in \ref destination_map
+///
+/// \returns On success, will return 'true' and the offsets in \ref
+/// destination_map
/// are usable copies of \ref source_map.
template <class D, class O>
static bool ImportOffsetMap(clang::ASTContext *dest_ctx,
@@ -574,7 +575,7 @@ static bool ImportOffsetMap(clang::ASTContext *dest_ctx,
/// \param[in] record The record that we're calculating the base layouts of.
/// \param[out] base_offsets Map of base-class decl to integral offset which
/// this function will fill in.
-///
+///
/// \returns On success, will return 'true' and the offsets in \ref base_offsets
/// are usable.
template <bool IsVirtual>
diff --git a/lldb/source/Plugins/ExpressionParser/Clang/ClangASTImporter.h b/lldb/source/Plugins/ExpressionParser/Clang/ClangASTImporter.h
index 98cf4ba360..bc962e544d 100644
--- a/lldb/source/Plugins/ExpressionParser/Clang/ClangASTImporter.h
+++ b/lldb/source/Plugins/ExpressionParser/Clang/ClangASTImporter.h
@@ -139,8 +139,8 @@ public:
/// \param[out] vbase_offsets Offsets of virtual base classes of \ref record.
///
/// \returns Returns 'false' if no valid origin was found for \ref record or
- /// this function failed to import the layout from the origin. Otherwise, returns
- /// 'true' and the offsets/size/alignment are valid for use.
+ /// this function failed to import the layout from the origin. Otherwise,
+ /// returns 'true' and the offsets/size/alignment are valid for use.
bool importRecordLayoutFromOrigin(
const clang::RecordDecl *record, uint64_t &size, uint64_t &alignment,
llvm::DenseMap<const clang::FieldDecl *, uint64_t> &field_offsets,
``````````
</details>
https://github.com/llvm/llvm-project/pull/83291
More information about the lldb-commits
mailing list