================ @@ -408,17 +408,26 @@ class ElementsAttrBase<Pred condition, string summary> : let storageType = [{ ::mlir::ElementsAttr }]; let returnType = [{ ::mlir::ElementsAttr }]; let convertFromStorage = "$_self"; + + // The underlying C++ value type of each element. + string elementReturnType = ?; ---------------- kparzysz wrote:
This may need wider support, specifically we may need to generate an accessor function in .h.inc/.cpp.inc. Something like https://github.com/llvm/llvm-project/blob/main/mlir/tools/mlir-tblgen/OpDefinitionsGen.cpp#L1204, for example. I'm wary about making this kind of change in a widely shared file. Maybe we could just handle this in OmpOpGen.cpp? Specifically, infer this information in there based on the type of the attribute? https://github.com/llvm/llvm-project/pull/99508 _______________________________________________ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits