From 6f54996a23988d165350e337a97018ecc3c84af7 Mon Sep 17 00:00:00 2001 From: David Blaikie Date: Mon, 13 Mar 2017 21:46:14 +0000 Subject: [PATCH] Remove unused lambda capture git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@297675 91177308-0d34-0410-b5e6-96231b3b80d8 --- tools/llvm-link/llvm-link.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/llvm-link/llvm-link.cpp b/tools/llvm-link/llvm-link.cpp index 6cb647d48eb..a024b6926d5 100644 --- a/tools/llvm-link/llvm-link.cpp +++ b/tools/llvm-link/llvm-link.cpp @@ -318,7 +318,7 @@ static bool linkFiles(const char *argv0, LLVMContext &Context, Linker &L, if (InternalizeLinkedSymbols) { Err = L.linkInModule( std::move(M), ApplicableFlags, [](Module &M, const StringSet<> &GVS) { - internalizeModule(M, [&M, &GVS](const GlobalValue &GV) { + internalizeModule(M, [&GVS](const GlobalValue &GV) { return !GV.hasName() || (GVS.count(GV.getName()) == 0); }); }); -- 2.50.1