Skip to content

Commit 8d7305b

Browse files
Fix type conflicts
1 parent 47acfec commit 8d7305b

File tree

1 file changed

+5
-3
lines changed
  • flang/include/flang/Lower/Support

1 file changed

+5
-3
lines changed

flang/include/flang/Lower/Support/Utils.h

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -551,8 +551,8 @@ class IsEqualEvaluateExpr {
551551
isEqual(x.upper(), y.upper()) && isEqual(x.stride(), y.stride());
552552
}
553553
template <typename A>
554-
static bool isEqual(const Fortran::evaluate::ArrayConstructorValue<A> &x,
555-
const Fortran::evaluate::ArrayConstructorValue<A> &y) {
554+
static bool isEqual(const Fortran::evaluate::ArrayConstructorValues<A> &x,
555+
const Fortran::evaluate::ArrayConstructorValues<A> &y) {
556556
using Expr = Fortran::evaluate::Expr<A>;
557557
using ImpliedDo = Fortran::evaluate::ImpliedDo<A>;
558558
for (const auto &[xValue, yValue] : llvm::zip(x, y)) {
@@ -579,7 +579,9 @@ class IsEqualEvaluateExpr {
579579
if constexpr (A::category == Fortran::common::TypeCategory::Character) {
580580
checkCharacterType = x.LEN() == y.LEN();
581581
}
582-
return isEqual(x, y) && x.GetType() == y.GetType() && checkCharacterType;
582+
using Base = Fortran::evaluate::ArrayConstructorValues<A>;
583+
return isEqual((Base) x, (Base) y) &&
584+
(x.GetType() == y.GetType() && checkCharacterType);
583585
}
584586
static bool isEqual(const Fortran::evaluate::ImpliedDoIndex &x,
585587
const Fortran::evaluate::ImpliedDoIndex &y) {

0 commit comments

Comments
 (0)