[llvm] 36c78ec - [DebugInfo] Use llvm::remove_if (NFC) (#149543)
via llvm-commits
llvm-commits at lists.llvm.org
Fri Jul 18 13:32:53 PDT 2025
Author: Kazu Hirata
Date: 2025-07-18T13:32:49-07:00
New Revision: 36c78ec3c8641cb193ea66f49da01fa6f62280d7
URL: https://github.com/llvm/llvm-project/commit/36c78ec3c8641cb193ea66f49da01fa6f62280d7
DIFF: https://github.com/llvm/llvm-project/commit/36c78ec3c8641cb193ea66f49da01fa6f62280d7.diff
LOG: [DebugInfo] Use llvm::remove_if (NFC) (#149543)
We can pass a range to llvm::remove_if.
Added:
Modified:
llvm/lib/DebugInfo/LogicalView/Core/LVScope.cpp
Removed:
################################################################################
diff --git a/llvm/lib/DebugInfo/LogicalView/Core/LVScope.cpp b/llvm/lib/DebugInfo/LogicalView/Core/LVScope.cpp
index 93a567e89f774..64f1bfc015380 100644
--- a/llvm/lib/DebugInfo/LogicalView/Core/LVScope.cpp
+++ b/llvm/lib/DebugInfo/LogicalView/Core/LVScope.cpp
@@ -263,7 +263,7 @@ bool LVScope::removeElement(LVElement *Element) {
return Item == Element;
};
auto RemoveElement = [Element, Predicate](auto &Container) -> bool {
- auto Iter = std::remove_if(Container->begin(), Container->end(), Predicate);
+ auto Iter = llvm::remove_if(*Container, Predicate);
if (Iter != Container->end()) {
Container->erase(Iter, Container->end());
Element->resetParent();
More information about the llvm-commits
mailing list