Author: Mikael Holmen Date: 2024-04-04T15:07:36+02:00 New Revision: 417a068b63c01d79511fe3732dd52377b05d06fc
URL: https://github.com/llvm/llvm-project/commit/417a068b63c01d79511fe3732dd52377b05d06fc DIFF: https://github.com/llvm/llvm-project/commit/417a068b63c01d79511fe3732dd52377b05d06fc.diff LOG: [clang][CGBlocks] Remove unused variable "refType" [NFC] Without the change gcc warned like ../../clang/lib/CodeGen/CGBlocks.cpp:965:21: warning: unused variable 'refType' [-Wunused-variable] 965 | } else if (auto refType = type->getAs<ReferenceType>()) { | ^~~~~~~ Added: Modified: clang/lib/CodeGen/CGBlocks.cpp Removed: ################################################################################ diff --git a/clang/lib/CodeGen/CGBlocks.cpp b/clang/lib/CodeGen/CGBlocks.cpp index a01f2c7c979840..47f063b5501cc6 100644 --- a/clang/lib/CodeGen/CGBlocks.cpp +++ b/clang/lib/CodeGen/CGBlocks.cpp @@ -962,7 +962,7 @@ llvm::Value *CodeGenFunction::EmitBlockLiteral(const CGBlockInfo &blockInfo) { } // If it's a reference variable, copy the reference into the block field. - } else if (auto refType = type->getAs<ReferenceType>()) { + } else if (type->getAs<ReferenceType>()) { Builder.CreateStore(src.emitRawPointer(*this), blockField); // If type is const-qualified, copy the value into the block field. _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits