@@ -1003,9 +1003,9 @@ class ScalarExprLowering {
10031003 },
10041004 [&](const fir::MutableBoxValue &toBox) {
10051005 if (toBox.isPointer ()) {
1006- Fortran::lower::associateMutableBox (converter, loc, toBox, expr,
1007- /* lbounds= */ std:: nullopt ,
1008- stmtCtx);
1006+ Fortran::lower::associateMutableBox (
1007+ converter, loc, toBox, expr ,
1008+ /* lbounds= */ mlir::ValueRange{}, stmtCtx);
10091009 return ;
10101010 }
10111011 // For allocatable components, a deep copy is needed.
@@ -3604,8 +3604,9 @@ class ArrayExprLowering {
36043604 mlir::Value castTo =
36053605 builder.createConvert (loc, fir::HeapType::get (seqTy), load);
36063606 mlir::Value shapeOp = builder.genShape (loc, shape);
3607- return builder.create <fir::ArrayLoadOp>(
3608- loc, seqTy, castTo, shapeOp, /* slice=*/ mlir::Value{}, std::nullopt );
3607+ return builder.create <fir::ArrayLoadOp>(loc, seqTy, castTo, shapeOp,
3608+ /* slice=*/ mlir::Value{},
3609+ mlir::ValueRange{});
36093610 };
36103611 // Custom lowering of the element store to deal with the extra indirection
36113612 // to the lazy allocated buffer.
@@ -4207,7 +4208,7 @@ class ArrayExprLowering {
42074208 auto addr =
42084209 builder->create <fir::ArrayCoorOp>(loc, eleRefTy, tmp, shape,
42094210 /* slice=*/ mlir::Value{}, indices,
4210- /* typeParams=*/ std:: nullopt );
4211+ /* typeParams=*/ mlir::ValueRange{} );
42114212 auto load = builder->create <fir::LoadOp>(loc, addr);
42124213 return builder->createConvert (loc, i1Ty, load);
42134214 };
@@ -4522,17 +4523,18 @@ class ArrayExprLowering {
45224523 fir::isRecordWithAllocatableMember (eleTy))
45234524 TODO (loc, " creating an array temp where the element type has "
45244525 " allocatable members" );
4525- mlir::Value temp = !seqTy.hasDynamicExtents ()
4526- ? builder.create <fir::AllocMemOp>(loc, type)
4527- : builder.create <fir::AllocMemOp>(
4528- loc, type, " .array.expr" , std::nullopt , shape);
4526+ mlir::Value temp =
4527+ !seqTy.hasDynamicExtents ()
4528+ ? builder.create <fir::AllocMemOp>(loc, type)
4529+ : builder.create <fir::AllocMemOp>(loc, type, " .array.expr" ,
4530+ mlir::ValueRange{}, shape);
45294531 fir::FirOpBuilder *bldr = &converter.getFirOpBuilder ();
45304532 stmtCtx.attachCleanup (
45314533 [bldr, loc, temp]() { bldr->create <fir::FreeMemOp>(loc, temp); });
45324534 mlir::Value shapeOp = genShapeOp (shape);
45334535 return builder.create <fir::ArrayLoadOp>(loc, seqTy, temp, shapeOp,
45344536 /* slice=*/ mlir::Value{},
4535- std:: nullopt );
4537+ mlir::ValueRange{} );
45364538 }
45374539
45384540 static fir::ShapeOp genShapeOp (mlir::Location loc, fir::FirOpBuilder &builder,
@@ -6483,7 +6485,7 @@ class ArrayExprLowering {
64836485 mlir::Value initBuffSz =
64846486 builder.createIntegerConstant (loc, idxTy, clInitialBufferSize);
64856487 mem = builder.create <fir::AllocMemOp>(
6486- loc, eleTy, /* typeparams=*/ std:: nullopt , initBuffSz);
6488+ loc, eleTy, /* typeparams=*/ mlir::ValueRange{} , initBuffSz);
64876489 builder.create <fir::StoreOp>(loc, initBuffSz, buffSize);
64886490 }
64896491 } else {
0 commit comments