[Mlir-commits] [mlir] [MLIR][Python] Impl XOpInterface(s) from Python, with X=Transform and X=MemoryEffects (PR #176920)

Maksim Levental llvmlistbot at llvm.org
Thu Feb 12 00:15:09 PST 2026


================
@@ -1872,13 +1873,20 @@ class MLIR_PYTHON_API_EXPORTED NoTerminator : public PyDynamicOpTrait {
 MLIR_PYTHON_API_EXPORTED MlirValue getUniqueResult(MlirOperation operation);
 MLIR_PYTHON_API_EXPORTED void populateIRCore(nanobind::module_ &m);
 MLIR_PYTHON_API_EXPORTED void populateRoot(nanobind::module_ &m);
+
+/// Helper for creating an @classmethod.
+template <class Func, typename... Args>
+static nanobind::object classmethod(Func f, Args... args) {
----------------
makslevental wrote:

rather than static it should be `inline` otherwise you will get linker errors when buliding `libMLIRPythonSupport`

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


More information about the Mlir-commits mailing list