@@ -601,7 +601,7 @@ class fir_IntegralSwitchTerminatorOp<string mnemonic,
601
601
p.printOperand(getSelector());
602
602
p << " : " << getSelector().getType() << " [";
603
603
auto cases =
604
- (*this)->getAttrOfType<mlir::ArrayAttr>(getCasesAttr()).getValue();
604
+ (*this)->getAttrOfType<mlir::ArrayAttr>(getCasesAttr()).getValue();
605
605
auto count = getNumConditions();
606
606
for (decltype(count) i = 0; i != count; ++i) {
607
607
if (i)
@@ -625,7 +625,8 @@ class fir_IntegralSwitchTerminatorOp<string mnemonic,
625
625
getSelector().getType().isa<mlir::IndexType>() ||
626
626
getSelector().getType().isa<fir::IntegerType>()))
627
627
return emitOpError("must be an integer");
628
- auto cases = (*this)->getAttrOfType<mlir::ArrayAttr>(getCasesAttr()).getValue();
628
+ auto cases =
629
+ (*this)->getAttrOfType<mlir::ArrayAttr>(getCasesAttr()).getValue();
629
630
auto count = getNumDest();
630
631
if (count == 0)
631
632
return emitOpError("must have at least one successor");
@@ -888,7 +889,7 @@ def fir_EmboxOp : fir_Op<"embox", [NoSideEffect, AttrSizedOperandSegments]> {
888
889
889
890
def fir_ReboxOp : fir_Op<"rebox", [NoSideEffect, AttrSizedOperandSegments]> {
890
891
let summary =
891
- "create a box given another box and (optional) dimension information";
892
+ "create a box given another box and (optional) dimension information";
892
893
893
894
let description = [{
894
895
Create a new boxed reference value from another box. This is meant to be
@@ -1513,13 +1514,16 @@ def fir_ArrayModifyOp : fir_Op<"array_modify", [AttrSizedOperandSegments,
1513
1514
```mlir
1514
1515
%s = fir.shape %n : (index) -> !fir.shape<1>
1515
1516
// Load the entire array 'a'.
1516
- %v = fir.array_load %a(%s) : (!fir.ref<!fir.array<?xf32>>, !fir.shape<1>) -> !fir.array<?xf32>
1517
+ %v = fir.array_load %a(%s) : (!fir.ref<!fir.array<?xf32>>, !fir.shape<1>)
1518
+ -> !fir.array<?xf32>
1517
1519
// Update the value of one of the array value's elements with a user
1518
1520
// defined assignment from %rhs.
1519
1521
%new = fir.do_loop %i = ... (%inner = %v) {
1520
1522
%rhs = ...
1521
- %addr, %r = fir.array_modify %inner, %i, %j : (!fir.array<?xf32>, index) -> fir.ref<f32>, !fir.array<?xf32>
1522
- fir.call @user_def_assign(%addr, %rhs) (fir.ref<f32>, fir.ref<!fir.type<SomeType>>) -> ()
1523
+ %addr, %r = fir.array_modify %inner, %i, %j : (!fir.array<?xf32>,
1524
+ index) -> fir.ref<f32>, !fir.array<?xf32>
1525
+ fir.call @user_def_assign(%addr, %rhs) (fir.ref<f32>,
1526
+ fir.ref<!fir.type<SomeType>>) -> ()
1523
1527
fir.result %r : !fir.ref<!fir.array<?xf32>>
1524
1528
}
1525
1529
fir.array_merge_store %v, %new to %a : !fir.ref<!fir.array<?xf32>>
@@ -1544,7 +1548,7 @@ def fir_ArrayModifyOp : fir_Op<"array_modify", [AttrSizedOperandSegments,
1544
1548
`:` functional-type(operands, results)
1545
1549
}];
1546
1550
1547
- let verifier = [{ return ::verify(*this); }] ;
1551
+ let verifier = " return ::verify(*this);" ;
1548
1552
}
1549
1553
1550
1554
def fir_ArrayAccessOp : fir_Op<"array_access", [AttrSizedOperandSegments,
0 commit comments