[llvm] [EquivalenceClasses] Introduce erase member function (PR #134660)
Jakub Kuderski via llvm-commits
llvm-commits at lists.llvm.org
Mon Apr 7 09:51:21 PDT 2025
================
@@ -78,11 +78,13 @@ template <class ElemTy> class EquivalenceClasses {
// ECValue ctor - Start out with EndOfList pointing to this node, Next is
// Null, isLeader = true.
ECValue(const ElemTy &Elt)
- : Leader(this), Next((ECValue*)(intptr_t)1), Data(Elt) {}
+ : Leader(this), Next((ECValue *)(intptr_t)1), Data(Elt) {}
const ECValue *getLeader() const {
- if (isLeader()) return this;
- if (Leader->isLeader()) return Leader;
+ if (isLeader())
+ return this;
+ if (Leader->isLeader())
+ return Leader;
----------------
kuhar wrote:
+1, you can land a separate clean-up PR (NFC) that fixes formatting
https://github.com/llvm/llvm-project/pull/134660
More information about the llvm-commits
mailing list