From c0132de0d56a28df2bf7f65c725b541b8eb62227 Mon Sep 17 00:00:00 2001 From: mlevesquedion Date: Thu, 2 May 2024 16:06:01 -0700 Subject: [PATCH] Use free function instead of method for dyn_cast_or_null (#2280) The method variant is deprecated. --- .../conversions/linalg/transforms/StablehloLegalizeToLinalg.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stablehlo/conversions/linalg/transforms/StablehloLegalizeToLinalg.cpp b/stablehlo/conversions/linalg/transforms/StablehloLegalizeToLinalg.cpp index 15853d1faee..ad7954d7d2b 100644 --- a/stablehlo/conversions/linalg/transforms/StablehloLegalizeToLinalg.cpp +++ b/stablehlo/conversions/linalg/transforms/StablehloLegalizeToLinalg.cpp @@ -829,7 +829,7 @@ struct TransposeOpToTransposeConverter final // TODO(#2216) Cleanup Attribute -> DenseArrayAttr rewriter.replaceOpWithNewOp( op, adaptor.getOperand(), emptyTensor, - op.getPermutationAttr().dyn_cast_or_null(), + dyn_cast_or_null(op.getPermutationAttr()), linalg::getPrunedAttributeList(op)); return success(); }