mirror of
https://github.com/intel/llvm.git
synced 2026-01-16 05:32:28 +08:00
[mlir][python] expose operation.block (#145088)
Expose `operation-getBlock()` in python.
This commit is contained in:
@@ -3385,6 +3385,7 @@ void mlir::python::populateIRCore(nb::module_ &m) {
|
||||
.def(MLIR_PYTHON_CAPI_FACTORY_ATTR, &PyOperation::createFromCapsule)
|
||||
.def_prop_ro("operation", [](nb::object self) { return self; })
|
||||
.def_prop_ro("opview", &PyOperation::createOpView)
|
||||
.def_prop_ro("block", &PyOperation::getBlock)
|
||||
.def_prop_ro(
|
||||
"successors",
|
||||
[](PyOperationBase &self) {
|
||||
|
||||
Reference in New Issue
Block a user