================ @@ -52,6 +52,14 @@ class Address { elementType); } + Address(mlir::Value pointer, clang::CharUnits alignment) + : Address(pointer, + mlir::cast<cir::PointerType>(pointer.getType()).getPointee(), ---------------- andykaylor wrote:
The thing that's being cast is `pointer.getType()` and `pointer` is an `mlir::Value` which can basically be any operation that has a pointer type. There is no common base class other than `mlir::Value` that can be used here. https://github.com/llvm/llvm-project/pull/129167 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits