[Mlir-commits] [mlir] [mlir][vector] Fix deprecation warning for `.isa`. NFC. (PR #135512)

llvmlistbot at llvm.org llvmlistbot at llvm.org
Sat Apr 12 18:43:51 PDT 2025


llvmbot wrote:


<!--LLVM PR SUMMARY COMMENT-->

@llvm/pr-subscribers-mlir

Author: Jakub Kuderski (kuhar)

<details>
<summary>Changes</summary>

This was introduced in: https://github.com/llvm/llvm-project/pull/135371

---
Full diff: https://github.com/llvm/llvm-project/pull/135512.diff


1 Files Affected:

- (modified) mlir/lib/Dialect/Vector/IR/VectorOps.cpp (+1-1) 


``````````diff
diff --git a/mlir/lib/Dialect/Vector/IR/VectorOps.cpp b/mlir/lib/Dialect/Vector/IR/VectorOps.cpp
index fdbdc72c057af..4dadecd4995d4 100644
--- a/mlir/lib/Dialect/Vector/IR/VectorOps.cpp
+++ b/mlir/lib/Dialect/Vector/IR/VectorOps.cpp
@@ -5348,7 +5348,7 @@ class FoldContiguousGather final : public OpRewritePattern<GatherOp> {
   using OpRewritePattern::OpRewritePattern;
   LogicalResult matchAndRewrite(GatherOp op,
                                 PatternRewriter &rewriter) const override {
-    if (!op.getBase().getType().isa<MemRefType>())
+    if (!isa<MemRefType>(op.getBase().getType()))
       return rewriter.notifyMatchFailure(op, "base must be of memref type");
 
     if (failed(isZeroBasedContiguousSeq(op.getIndexVec())))

``````````

</details>


https://github.com/llvm/llvm-project/pull/135512


More information about the Mlir-commits mailing list