Skip to content

Commit 227f759

Browse files
authored
[mlir][python] expose operation.block (#145088)
Expose `operation-getBlock()` in python.
1 parent affcc5e commit 227f759

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

mlir/lib/Bindings/Python/IRCore.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3385,6 +3385,7 @@ void mlir::python::populateIRCore(nb::module_ &m) {
33853385
.def(MLIR_PYTHON_CAPI_FACTORY_ATTR, &PyOperation::createFromCapsule)
33863386
.def_prop_ro("operation", [](nb::object self) { return self; })
33873387
.def_prop_ro("opview", &PyOperation::createOpView)
3388+
.def_prop_ro("block", &PyOperation::getBlock)
33883389
.def_prop_ro(
33893390
"successors",
33903391
[](PyOperationBase &self) {

0 commit comments

Comments
 (0)