Fields of unsupported type can be represented as opaque blobs of bytes.
After this CL the IR::Field::type value is wrapped in absl::StatusOr (or
Result<_, String> on Rust side) - an error means an unsupported type.
PiperOrigin-RevId: 449355244
diff --git a/rs_bindings_from_cc/ir.h b/rs_bindings_from_cc/ir.h
index 9c5431b..d6f3394 100644
--- a/rs_bindings_from_cc/ir.h
+++ b/rs_bindings_from_cc/ir.h
@@ -22,6 +22,7 @@
#include <vector>
#include "absl/container/flat_hash_map.h"
+#include "absl/status/statusor.h"
#include "absl/strings/string_view.h"
#include "common/check.h"
#include "common/strong_int.h"
@@ -479,7 +480,7 @@
llvm::Optional<Identifier> identifier;
llvm::Optional<std::string> doc_comment;
- MappedType type;
+ absl::StatusOr<MappedType> type;
AccessSpecifier access;
// Field offset in bits.
uint64_t offset;