[lld] r255846 - Simplify. NFC.

Rui Ueyama via llvm-commits llvm-commits at lists.llvm.org
Wed Dec 16 15:25:31 PST 2015


Author: ruiu
Date: Wed Dec 16 17:25:31 2015
New Revision: 255846

URL: http://llvm.org/viewvc/llvm-project?rev=255846&view=rev
Log:
Simplify. NFC.

Modified:
    lld/trunk/ELF/SymbolTable.cpp

Modified: lld/trunk/ELF/SymbolTable.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/ELF/SymbolTable.cpp?rev=255846&r1=255845&r2=255846&view=diff
==============================================================================
--- lld/trunk/ELF/SymbolTable.cpp (original)
+++ lld/trunk/ELF/SymbolTable.cpp Wed Dec 16 17:25:31 2015
@@ -185,11 +185,8 @@ template <class ELFT> Symbol *SymbolTabl
   // Find an existing Symbol or create and insert a new one.
   StringRef Name = New->getName();
   Symbol *&Sym = Symtab[Name];
-  if (!Sym) {
+  if (!Sym)
     Sym = new (Alloc) Symbol(New);
-    New->setBackref(Sym);
-    return Sym;
-  }
   New->setBackref(Sym);
   return Sym;
 }




More information about the llvm-commits mailing list