[Mlir-commits] [mlir] [mlir][py] Overload print with state. (PR #72064)

Maksim Levental llvmlistbot at llvm.org
Sun Nov 12 11:56:12 PST 2023


================
@@ -2946,15 +2967,23 @@ void mlir::python::populateIRCore(py::module &m) {
                                /*assumeVerified=*/false);
           },
           "Returns the assembly form of the operation.")
-      .def("print", &PyOperationBase::print,
+      .def("print",
+           py::overload_cast<PyAsmState &, pybind11::object, bool>(
----------------
makslevental wrote:

```suggestion
           py::overload_cast<PyAsmState &, py::object, bool>(
```

https://github.com/llvm/llvm-project/pull/72064


More information about the Mlir-commits mailing list