[flang-commits] [flang] [flang][openmp]Add UserReductionDetails and use in DECLARE REDUCTION (PR #131628)

Mats Petersson via flang-commits flang-commits at lists.llvm.org
Wed Mar 26 10:53:21 PDT 2025


================
@@ -3464,9 +3466,11 @@ static bool IsReductionAllowedForType(
       case parser::DefinedOperator::IntrinsicOperator::Multiply:
       case parser::DefinedOperator::IntrinsicOperator::Add:
       case parser::DefinedOperator::IntrinsicOperator::Subtract:
-        return type.IsNumeric(TypeCategory::Integer) ||
+        if (type.IsNumeric(TypeCategory::Integer) ||
             type.IsNumeric(TypeCategory::Real) ||
-            type.IsNumeric(TypeCategory::Complex);
+            type.IsNumeric(TypeCategory::Complex))
+          return true;
+        break;
----------------
Leporacanthicus wrote:

Yes. 

https://github.com/llvm/llvm-project/pull/131628


More information about the flang-commits mailing list