[flang-commits] [flang] 2a1d222 - [flang] Fix compilation error due to variable no being used (#75210)

via flang-commits flang-commits at lists.llvm.org
Tue Dec 12 08:15:57 PST 2023


Author: Pete Steinfeld
Date: 2023-12-12T08:15:53-08:00
New Revision: 2a1d222010266147c6767f34b25c5a91c93b55de

URL: https://github.com/llvm/llvm-project/commit/2a1d222010266147c6767f34b25c5a91c93b55de
DIFF: https://github.com/llvm/llvm-project/commit/2a1d222010266147c6767f34b25c5a91c93b55de.diff

LOG: [flang] Fix compilation error due to variable no being used (#75210)

My builds were failing because the variable 'dim' was not used. This
produced a warning, and my builds have warnings set as errors.

Added: 
    

Modified: 
    flang/lib/Optimizer/HLFIR/IR/HLFIROps.cpp

Removed: 
    


################################################################################
diff  --git a/flang/lib/Optimizer/HLFIR/IR/HLFIROps.cpp b/flang/lib/Optimizer/HLFIR/IR/HLFIROps.cpp
index 6af2888b3a60d..46eee8acac24b 100644
--- a/flang/lib/Optimizer/HLFIR/IR/HLFIROps.cpp
+++ b/flang/lib/Optimizer/HLFIR/IR/HLFIROps.cpp
@@ -663,7 +663,6 @@ template <typename NumericalReductionOp>
 static mlir::LogicalResult
 verifyArrayAndMaskForReductionOp(NumericalReductionOp reductionOp) {
   mlir::Value array = reductionOp->getArray();
-  mlir::Value dim = reductionOp->getDim();
   mlir::Value mask = reductionOp->getMask();
 
   fir::SequenceType arrayTy =


        


More information about the flang-commits mailing list