Implement the C-API and Python bindings for the builtin opaque type, which was previously missing.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Thanks! This looks good, I only have a couple of nits and a small request to add a test for the C API somewhere here https://github.com/llvm/llvm-project/blob/main/mlir/test/CAPI/ir.c#L625.
mlir/include/mlir-c/BuiltinTypes.h | ||
---|---|---|
340–341 | Any reason why the data is not accepted as MlirStringRef? It is returned as such, so I'd go for consistency here. | |
mlir/lib/Bindings/Python/IRTypes.cpp | ||
636 | Nit: add trailing dots in the documentation here and below. |
mlir/include/mlir-c/BuiltinTypes.h | ||
---|---|---|
340–341 | Hmm good question, I wanted to be consistent with the OpaqueAttribute , but I can change it. |
mlir/include/mlir-c/BuiltinTypes.h | ||
---|---|---|
340–341 | That seems to have been overlooked when we introduced MlirStringRef, it is also worth changing :) |
Implement suggestions from code review
- punctuation in docstrings
- use StringRef instead of char*
- add C-API test
Any reason why the data is not accepted as MlirStringRef? It is returned as such, so I'd go for consistency here.