[clang] 0cbbfb8 - [CGCall] Prune ArgStruct [-Wunused-variable]

NAKAMURA Takumi via cfe-commits cfe-commits at lists.llvm.org
Thu Jun 15 16:06:58 PDT 2023


Author: NAKAMURA Takumi
Date: 2023-06-16T08:00:57+09:00
New Revision: 0cbbfb8c2e03275e2f67e4f953693601785069a4

URL: https://github.com/llvm/llvm-project/commit/0cbbfb8c2e03275e2f67e4f953693601785069a4
DIFF: https://github.com/llvm/llvm-project/commit/0cbbfb8c2e03275e2f67e4f953693601785069a4.diff

LOG: [CGCall] Prune ArgStruct [-Wunused-variable]

It has been unused since b92ccc355acb

Added: 
    

Modified: 
    clang/lib/CodeGen/CGCall.cpp

Removed: 
    


################################################################################
diff  --git a/clang/lib/CodeGen/CGCall.cpp b/clang/lib/CodeGen/CGCall.cpp
index 71268d9abcbda..fc77566c790c1 100644
--- a/clang/lib/CodeGen/CGCall.cpp
+++ b/clang/lib/CodeGen/CGCall.cpp
@@ -1666,12 +1666,9 @@ CodeGenTypes::GetFunctionType(const CGFunctionInfo &FI) {
   }
 
   // Add type for inalloca argument.
-  if (IRFunctionArgs.hasInallocaArg()) {
-    auto ArgStruct = FI.getArgStruct();
-    assert(ArgStruct);
+  if (IRFunctionArgs.hasInallocaArg())
     ArgTypes[IRFunctionArgs.getInallocaArgNo()] =
         llvm::PointerType::getUnqual(getLLVMContext());
-  }
 
   // Add in all of the required arguments.
   unsigned ArgNo = 0;


        


More information about the cfe-commits mailing list