[ELF] Reduce the code indentation
authorSimon Atanasyan <simon@atanasyan.com>
Thu, 26 Feb 2015 20:09:42 +0000 (20:09 +0000)
committerSimon Atanasyan <simon@atanasyan.com>
Thu, 26 Feb 2015 20:09:42 +0000 (20:09 +0000)
No functional changes.

llvm-svn: 230678

lld/lib/ReaderWriter/ELF/ELFFile.h

index 869efe1..22891c2 100644 (file)
@@ -1089,18 +1089,17 @@ void ELFFile<ELFT>::updateReferenceForMergeStringAccess(ELFReference<ELFT> *ref,
 
 template <class ELFT> void ELFFile<ELFT>::updateReferences() {
   for (auto &ri : _references) {
-    if (ri->kindNamespace() == lld::Reference::KindNamespace::ELF) {
-      const Elf_Sym *symbol = _objFile->getSymbol(ri->targetSymbolIndex());
-      const Elf_Shdr *shdr = _objFile->getSection(symbol);
-
-      // If the atom is not in mergeable string section, the target atom is
-      // simply that atom.
-      if (!isMergeableStringSection(shdr)) {
-        ri->setTarget(findAtom(findSymbolForReference(ri), symbol));
-        continue;
-      }
+    if (ri->kindNamespace() != lld::Reference::KindNamespace::ELF)
+      continue;
+    const Elf_Sym *symbol = _objFile->getSymbol(ri->targetSymbolIndex());
+    const Elf_Shdr *shdr = _objFile->getSection(symbol);
+
+    // If the atom is not in mergeable string section, the target atom is
+    // simply that atom.
+    if (isMergeableStringSection(shdr))
       updateReferenceForMergeStringAccess(ri, symbol, shdr);
-    }
+    else
+      ri->setTarget(findAtom(findSymbolForReference(ri), symbol));
   }
 }