Skip to content

Commit b434bc4

Browse files
authored
[CIR][NFC] Remove redundant pointer casts (#139898)
This mirrors incubator changes from llvm/clangir#1609
1 parent d47cd50 commit b434bc4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

clang/include/clang/CIR/Dialect/IR/CIROps.td

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,7 @@ def PtrStrideOp : CIR_Op<"ptr_stride",
269269
let extraClassDeclaration = [{
270270
// Get type pointed by the base pointer.
271271
mlir::Type getElementTy() {
272-
return mlir::cast<cir::PointerType>(getBase().getType()).getPointee();
272+
return getBase().getType().getPointee();
273273
}
274274
}];
275275
}
@@ -1710,7 +1710,7 @@ def GetMemberOp : CIR_Op<"get_member"> {
17101710

17111711
/// Return the result type.
17121712
cir::PointerType getResultTy() {
1713-
return mlir::cast<cir::PointerType>(getResult().getType());
1713+
return getResult().getType();
17141714
}
17151715
}];
17161716

0 commit comments

Comments
 (0)