[Mlir-commits] [mlir] [MLIR] [Python] Fixed the return type of static_typeid (PR #183021)

Maksim Levental llvmlistbot at llvm.org
Tue Feb 24 08:31:23 PST 2026


================
@@ -967,7 +967,8 @@ class MLIR_PYTHON_API_EXPORTED PyConcreteType : public BaseTy {
               (DerivedTy::pyClassName + std::string(" has no typeid."))
                   .c_str());
         },
-        nanobind::sig("def static_typeid(/) -> TypeID"));
+        nanobind::sig(
+            "def static_typeid(/) -> " MAKE_MLIR_PYTHON_QUALNAME("ir.TypeID")));
----------------
makslevental wrote:

Did you check the generated stubs for the core bindings? I believe this will generate the wrong thing for core types

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


More information about the Mlir-commits mailing list