From: Jessica Paquette Date: Thu, 24 Jan 2019 22:51:31 +0000 (+0000) Subject: Suppress unused capture warning in CheckCopy X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=647c8a7cfbd3ca9130e632a9a483eb653b44ed00;p=llvm Suppress unused capture warning in CheckCopy Werror bots didn't like the lambda + assert thing in my previous commit. Capture everything to suppress the error. Example failure here: http://lab.llvm.org:8011/builders/lld-x86_64-darwin13/builds/29393 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@352124 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/Target/AArch64/AArch64InstructionSelector.cpp b/lib/Target/AArch64/AArch64InstructionSelector.cpp index f08439c6262..e1536dead10 100644 --- a/lib/Target/AArch64/AArch64InstructionSelector.cpp +++ b/lib/Target/AArch64/AArch64InstructionSelector.cpp @@ -485,7 +485,7 @@ static bool selectCopy(MachineInstr &I, const TargetInstrInfo &TII, // Returns true, or asserts if something we don't expect happens. Instead of // returning true, we return isValidCopy() to ensure that we verify the // result. - auto CheckCopy = [&I, &DstRegBank, &MRI, &TRI, &RBI, &KnownValid]() { + auto CheckCopy = [&]() { // If we have a bitcast or something, we can't have physical registers. assert( I.isCopy() ||