[llvm] f95108f - [DWARFLinker] Clean up analyzeContextInfo signature (NFC)
Jonas Devlieghere via llvm-commits
llvm-commits at lists.llvm.org
Wed Jan 4 15:06:12 PST 2023
Author: Jonas Devlieghere
Date: 2023-01-04T15:01:58-08:00
New Revision: f95108f38a2dccf32cebd18e8e9ebf8c0b80ca80
URL: https://github.com/llvm/llvm-project/commit/f95108f38a2dccf32cebd18e8e9ebf8c0b80ca80
DIFF: https://github.com/llvm/llvm-project/commit/f95108f38a2dccf32cebd18e8e9ebf8c0b80ca80.diff
LOG: [DWARFLinker] Clean up analyzeContextInfo signature (NFC)
- Remove always-false flag.
- Remove unused return value.
Added:
Modified:
llvm/lib/DWARFLinker/DWARFLinker.cpp
Removed:
################################################################################
diff --git a/llvm/lib/DWARFLinker/DWARFLinker.cpp b/llvm/lib/DWARFLinker/DWARFLinker.cpp
index 9418dc254bc05..4a8c2c26f5368 100644
--- a/llvm/lib/DWARFLinker/DWARFLinker.cpp
+++ b/llvm/lib/DWARFLinker/DWARFLinker.cpp
@@ -313,15 +313,14 @@ static void updateChildPruning(const DWARFDie &Die, CompileUnit &CU,
/// \return true when this DIE and all of its children are only
/// forward declarations to types defined in external clang modules
/// (i.e., forward declarations that are children of a DW_TAG_module).
-static bool analyzeContextInfo(
+static void analyzeContextInfo(
const DWARFDie &DIE, unsigned ParentIdx, CompileUnit &CU,
DeclContext *CurrentDeclContext, DeclContextTree &Contexts,
uint64_t ModulesEndOffset, swiftInterfacesMap *ParseableSwiftInterfaces,
- std::function<void(const Twine &, const DWARFDie &)> ReportWarning,
- bool InImportedModule = false) {
+ std::function<void(const Twine &, const DWARFDie &)> ReportWarning) {
// LIFO work list.
std::vector<ContextWorklistItem> Worklist;
- Worklist.emplace_back(DIE, CurrentDeclContext, ParentIdx, InImportedModule);
+ Worklist.emplace_back(DIE, CurrentDeclContext, ParentIdx, false);
while (!Worklist.empty()) {
ContextWorklistItem Current = Worklist.back();
@@ -389,8 +388,6 @@ static bool analyzeContextInfo(
Current.InImportedModule);
}
}
-
- return CU.getInfo(DIE).Prune;
}
static bool dieNeedsChildrenToBeMeaningful(uint32_t Tag) {
More information about the llvm-commits
mailing list