Skip to content

Commit d45b1b6

Browse files
committed
[flang] Fix flang-aarch64-latest-gcc build failure due to f295c88
Insert a return statement
1 parent 7ed3c2e commit d45b1b6

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

flang/include/flang/Optimizer/Builder/IntrinsicCall.h

+4-2
Original file line numberDiff line numberDiff line change
@@ -560,21 +560,23 @@ static inline mlir::Type getTypeHelper(mlir::MLIRContext *context,
560560
break;
561561
}
562562

563+
mlir::Type fTy;
563564
switch (typeId) {
564565
case ParamTypeId::Void:
565566
case ParamTypeId::Integer:
566567
case ParamTypeId::Real:
567568
case ParamTypeId::Complex:
568569
// keep original type for void and non-vector
569-
return r;
570+
fTy = r;
570571
break;
571572
case ParamTypeId::IntegerVector:
572573
case ParamTypeId::UnsignedVector:
573574
case ParamTypeId::RealVector:
574575
// convert to FIR vector type
575-
return fir::VectorType::get(getVecLen(r), r);
576+
fTy = fir::VectorType::get(getVecLen(r), r);
576577
break;
577578
}
579+
return fTy;
578580
}
579581

580582
// Generic function type generator that supports most of the function types

0 commit comments

Comments
 (0)