From 119b9cdb388f33e78fbb2a73e244ec3031c7f84c Mon Sep 17 00:00:00 2001 From: Peter Klausler <35819229+klausler@users.noreply.github.com> Date: Mon, 8 Apr 2024 14:01:13 -0700 Subject: [PATCH] [flang][omp] Heed valid build warning (#88015) Address a bug found by a compiler warning, and thereby also fix -Werror builds. --- flang/lib/Lower/OpenMP/ReductionProcessor.h | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/flang/lib/Lower/OpenMP/ReductionProcessor.h b/flang/lib/Lower/OpenMP/ReductionProcessor.h index 7ea252fde3602e..8b116a4c520411 100644 --- a/flang/lib/Lower/OpenMP/ReductionProcessor.h +++ b/flang/lib/Lower/OpenMP/ReductionProcessor.h @@ -151,9 +151,8 @@ mlir::Value ReductionProcessor::getReductionOperation(fir::FirOpBuilder &builder, mlir::Type type, mlir::Location loc, mlir::Value op1, mlir::Value op2) { - assert(type.isIntOrIndexOrFloat() || - fir::isa_complex(type) && - "only integer, float and complex types are currently supported"); + assert((type.isIntOrIndexOrFloat() || fir::isa_complex(type)) && + "only integer, float and complex types are currently supported"); if (type.isIntOrIndex()) return builder.create(loc, op1, op2); if (fir::isa_real(type))