Skip to content

Commit

Permalink
Use enumerate
Browse files Browse the repository at this point in the history
  • Loading branch information
Michael Levesque-Dion committed Apr 29, 2024
1 parent 24f35ac commit f34ea2e
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions stablehlo/dialect/TypeInference.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3717,8 +3717,7 @@ LogicalResult verifyDynamicBroadcastInDimOp(
if (SmallVector<int64_t> shape;
operandType.hasStaticShape() &&
matchInts(outputDimensions, shape).succeeded()) {
for (int64_t i = 0; i != bcastDimensionsSize; ++i) {
auto dimIndex = broadcastDimensions[i];
for (auto [i, dimIndex] : llvm::enumerate(broadcastDimensions)) {
if (!operandType.isDynamicDim(i)) {
auto dimSize = operandType.getDimSize(i);
auto shapeDimSize = shape[dimIndex];
Expand Down

0 comments on commit f34ea2e

Please sign in to comment.