[lld] r244680 - ELF2: Remove unused global variable.

Rui Ueyama via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 11 14:45:55 PDT 2015


Author: ruiu
Date: Tue Aug 11 16:45:55 2015
New Revision: 244680

URL: http://llvm.org/viewvc/llvm-project?rev=244680&view=rev
Log:
ELF2: Remove unused global variable.

A global variable "Driver" is to re-entry to the driver to parse a
.drectve section. Because the need is COFF-specific, we don't need
this variable for ELF.

Modified:
    lld/trunk/ELF/Driver.cpp

Modified: lld/trunk/ELF/Driver.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/ELF/Driver.cpp?rev=244680&r1=244679&r2=244680&view=diff
==============================================================================
--- lld/trunk/ELF/Driver.cpp (original)
+++ lld/trunk/ELF/Driver.cpp Tue Aug 11 16:45:55 2015
@@ -23,14 +23,11 @@ using namespace lld::elf2;
 namespace lld {
 namespace elf2 {
 Configuration *Config;
-LinkerDriver *Driver;
 
 void link(ArrayRef<const char *> Args) {
   auto C = make_unique<Configuration>();
   Config = C.get();
-  auto D = make_unique<LinkerDriver>();
-  Driver = D.get();
-  Driver->link(Args.slice(1));
+  LinkerDriver().link(Args.slice(1));
 }
 
 }




More information about the llvm-commits mailing list