From: Jakub Kuderski Date: Wed, 30 Nov 2022 22:39:00 +0000 (-0500) Subject: [mlir][vector] Attempt to please gcc 9. NFC. X-Git-Tag: upstream/17.0.6~25803 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=ce0946d0b09cd9475af20ace182f744c969e0491;p=platform%2Fupstream%2Fllvm.git [mlir][vector] Attempt to please gcc 9. NFC. This is a post-commit fix to D139022. --- diff --git a/mlir/lib/Dialect/Vector/IR/VectorOps.cpp b/mlir/lib/Dialect/Vector/IR/VectorOps.cpp index 82216a8..7bbb120 100644 --- a/mlir/lib/Dialect/Vector/IR/VectorOps.cpp +++ b/mlir/lib/Dialect/Vector/IR/VectorOps.cpp @@ -2386,7 +2386,7 @@ isIntegerArrayAttrConfinedToShape(OpType op, ArrayAttr arrayAttr, bool halfOpen = true, int64_t min = 0) { unsigned index = 0; for (auto [attr, maxDim] : llvm::zip_first(arrayAttr, shape)) { - int64_t val = attr.cast().getInt(); + int64_t val = attr.template cast().getInt(); int64_t max = maxDim; if (!halfOpen) max += 1; @@ -2410,7 +2410,8 @@ static LogicalResult isSumOfIntegerArrayAttrConfinedToShape( assert(arrayAttr1.size() <= shape.size()); assert(arrayAttr2.size() <= shape.size()); unsigned index = 0; - for (auto it : llvm::zip(arrayAttr1, arrayAttr2, shape)) { + for (auto it : + llvm::zip(arrayAttr1, arrayAttr2, shape)) { auto val1 = std::get<0>(it).cast().getInt(); auto val2 = std::get<1>(it).cast().getInt(); int64_t max = std::get<2>(it);