aboutsummaryrefslogtreecommitdiff
path: root/mlir/lib/Bindings/Python/IRModule.h
diff options
context:
space:
mode:
authorMaksim Levental <maksim.levental@gmail.com>2025-10-02 11:18:47 -0400
committerGitHub <noreply@github.com>2025-10-02 08:18:47 -0700
commita3594cd6442ee988c18249d96b8331f0a5331df7 (patch)
tree9dfd29c6c10df55cc54f9ae12ce75c6472a40341 /mlir/lib/Bindings/Python/IRModule.h
parent197e77b33d344c162b8c87de8aa7ddd942f50874 (diff)
downloadllvm-a3594cd6442ee988c18249d96b8331f0a5331df7.zip
llvm-a3594cd6442ee988c18249d96b8331f0a5331df7.tar.gz
llvm-a3594cd6442ee988c18249d96b8331f0a5331df7.tar.bz2
[MLIR][Python] fixup Context and Location stubs and NanobindAdaptors (#161433)
add correct names for `NB_TYPE_CASTER(..., name)` so users of `NanobindAdaptors.h` can generate the correct hints. Also fix a few straggler stubs.
Diffstat (limited to 'mlir/lib/Bindings/Python/IRModule.h')
-rw-r--r--mlir/lib/Bindings/Python/IRModule.h6
1 files changed, 2 insertions, 4 deletions
diff --git a/mlir/lib/Bindings/Python/IRModule.h b/mlir/lib/Bindings/Python/IRModule.h
index 598ae01..edbd73e 100644
--- a/mlir/lib/Bindings/Python/IRModule.h
+++ b/mlir/lib/Bindings/Python/IRModule.h
@@ -273,8 +273,7 @@ class DefaultingPyMlirContext
: public Defaulting<DefaultingPyMlirContext, PyMlirContext> {
public:
using Defaulting::Defaulting;
- static constexpr const char kTypeDescription[] =
- MAKE_MLIR_PYTHON_QUALNAME("ir.Context");
+ static constexpr const char kTypeDescription[] = "Context";
static PyMlirContext &resolve();
};
@@ -500,8 +499,7 @@ class DefaultingPyLocation
: public Defaulting<DefaultingPyLocation, PyLocation> {
public:
using Defaulting::Defaulting;
- static constexpr const char kTypeDescription[] =
- MAKE_MLIR_PYTHON_QUALNAME("ir.Location");
+ static constexpr const char kTypeDescription[] = "Location";
static PyLocation &resolve();
operator MlirLocation() const { return *get(); }