[Mlir-commits] [mlir] [MLIR][Python] Register `OpAttributeMap` as `Mapping` for `match` compatibility (PR #174292)
Maksim Levental
llvmlistbot at llvm.org
Fri Jan 9 13:31:19 PST 2026
================
@@ -2388,6 +2388,16 @@ PyOpAttributeMap::dunderGetItemNamed(const std::string &name) {
return PyAttribute(operation->getContext(), attr).maybeDownCast();
}
+nb::object PyOpAttributeMap::getWithDefaultNamed(const std::string &key,
----------------
makslevental wrote:
```suggestion
nb::typed<nanobind::object, PyAttribute> PyOpAttributeMap::getWithDefaultNamed(const std::string &key,
```
https://github.com/llvm/llvm-project/pull/174292
More information about the Mlir-commits
mailing list