[llvm] r253889 - Remove unused function parameter (NFC)

Teresa Johnson via llvm-commits llvm-commits at lists.llvm.org
Mon Nov 23 09:42:49 PST 2015


Author: tejohnson
Date: Mon Nov 23 11:42:49 2015
New Revision: 253889

URL: http://llvm.org/viewvc/llvm-project?rev=253889&view=rev
Log:
Remove unused function parameter (NFC)

Modified:
    llvm/trunk/tools/llvm-link/llvm-link.cpp

Modified: llvm/trunk/tools/llvm-link/llvm-link.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/tools/llvm-link/llvm-link.cpp?rev=253889&r1=253888&r2=253889&view=diff
==============================================================================
--- llvm/trunk/tools/llvm-link/llvm-link.cpp (original)
+++ llvm/trunk/tools/llvm-link/llvm-link.cpp Mon Nov 23 11:42:49 2015
@@ -143,7 +143,7 @@ static void diagnosticHandler(const Diag
 
 /// Load a function index if requested by the -functionindex option.
 static ErrorOr<std::unique_ptr<FunctionInfoIndex>>
-loadIndex(LLVMContext &Context, const Module *ExportingModule = nullptr) {
+loadIndex(const Module *ExportingModule = nullptr) {
   assert(!FunctionIndex.empty());
   ErrorOr<std::unique_ptr<MemoryBuffer>> FileOrErr =
       MemoryBuffer::getFileOrSTDIN(FunctionIndex);
@@ -208,8 +208,7 @@ static bool importFunctions(const char *
 
     std::unique_ptr<FunctionInfoIndex> Index;
     if (!FunctionIndex.empty()) {
-      ErrorOr<std::unique_ptr<FunctionInfoIndex>> IndexOrErr =
-          loadIndex(Context);
+      ErrorOr<std::unique_ptr<FunctionInfoIndex>> IndexOrErr = loadIndex();
       std::error_code EC = IndexOrErr.getError();
       if (EC) {
         errs() << EC.message() << '\n';
@@ -246,8 +245,7 @@ static bool linkFiles(const char *argv0,
     // local functions/variables as exported and promote if necessary.
     std::unique_ptr<FunctionInfoIndex> Index;
     if (!FunctionIndex.empty()) {
-      ErrorOr<std::unique_ptr<FunctionInfoIndex>> IndexOrErr =
-          loadIndex(Context, &*M);
+      ErrorOr<std::unique_ptr<FunctionInfoIndex>> IndexOrErr = loadIndex(&*M);
       std::error_code EC = IndexOrErr.getError();
       if (EC) {
         errs() << EC.message() << '\n';




More information about the llvm-commits mailing list