[lld-macho][nfc] Rename isec -> referentIsec to avoid shadowing
authorJez Ng <jezng@fb.com>
Mon, 7 Mar 2022 04:27:35 +0000 (23:27 -0500)
committerJez Ng <jezng@fb.com>
Mon, 7 Mar 2022 17:36:28 +0000 (12:36 -0500)
I found the shadowing a bit confusing

lld/MachO/ICF.cpp

index 70317d4..885cb82 100644 (file)
@@ -282,8 +282,9 @@ void ICF::run() {
             hash += dylibSym->stubsHelperIndex;
           else if (auto *defined = dyn_cast<Defined>(sym)) {
             if (defined->isec) {
-              if (auto isec = dyn_cast<ConcatInputSection>(defined->isec))
-                hash += defined->value + isec->icfEqClass[icfPass % 2];
+              if (auto referentIsec =
+                      dyn_cast<ConcatInputSection>(defined->isec))
+                hash += defined->value + referentIsec->icfEqClass[icfPass % 2];
               else
                 hash += defined->isec->kind() +
                         defined->isec->getOffset(defined->value);