[Mlir-commits] [mlir] [mlir][affine] cleanup deprecated T.cast style functions (PR #71269)
Aart Bik
llvmlistbot at llvm.org
Thu Nov 9 16:16:47 PST 2023
================
@@ -24,61 +24,61 @@ Var DimLvlExpr::castAnyVar() const {
}
std::optional<Var> DimLvlExpr::dyn_castAnyVar() const {
- if (const auto s = expr.dyn_cast_or_null<AffineSymbolExpr>())
+ if (const auto s = dyn_cast_or_null<AffineSymbolExpr>(expr))
return SymVar(s);
- if (const auto x = expr.dyn_cast_or_null<AffineDimExpr>())
+ if (const auto x = dyn_cast_or_null<AffineDimExpr>(expr))
return Var(getAllowedVarKind(), x);
return std::nullopt;
}
SymVar DimLvlExpr::castSymVar() const {
- return SymVar(expr.cast<AffineSymbolExpr>());
+ return SymVar(llvm::cast<AffineSymbolExpr>(expr));
----------------
aartbik wrote:
please use one style, preferably without llvm:: prefix
https://github.com/llvm/llvm-project/pull/71269
More information about the Mlir-commits
mailing list