diff --git a/clang/include/clang/CIR/Dialect/IR/CIROps.td b/clang/include/clang/CIR/Dialect/IR/CIROps.td index 9f5fa266742e8..e08f372450285 100644 --- a/clang/include/clang/CIR/Dialect/IR/CIROps.td +++ b/clang/include/clang/CIR/Dialect/IR/CIROps.td @@ -269,7 +269,7 @@ def PtrStrideOp : CIR_Op<"ptr_stride", let extraClassDeclaration = [{ // Get type pointed by the base pointer. mlir::Type getElementTy() { - return mlir::cast(getBase().getType()).getPointee(); + return getBase().getType().getPointee(); } }]; } @@ -1710,7 +1710,7 @@ def GetMemberOp : CIR_Op<"get_member"> { /// Return the result type. cir::PointerType getResultTy() { - return mlir::cast(getResult().getType()); + return getResult().getType(); } }];