Bump upb version (#10779)
* bump upb version
* Update stale amalgamation files
diff --git a/ruby/ext/google/protobuf_c/ruby-upb.h b/ruby/ext/google/protobuf_c/ruby-upb.h
index bb71990..b9572d3 100755
--- a/ruby/ext/google/protobuf_c/ruby-upb.h
+++ b/ruby/ext/google/protobuf_c/ruby-upb.h
@@ -26,9 +26,9 @@
*/
#if !((defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L) || \
- (defined(__cplusplus) && __cplusplus >= 201103L) || \
+ (defined(__cplusplus) && __cplusplus >= 201402L) || \
(defined(_MSC_VER) && _MSC_VER >= 1900))
-#error upb requires C99 or C++11 or MSVC >= 2015.
+#error upb requires C99 or C++14 or MSVC >= 2015.
#endif
// Portable check for GCC minimum version:
@@ -516,6 +516,9 @@
* upb_MessageDef_MiniTable() but users cannot access any of the members. */
typedef struct upb_MiniTable upb_MiniTable;
+/* Creates a new message with the given mini_table on the given arena. */
+upb_Message* upb_Message_New(const upb_MiniTable* mini_table, upb_Arena* arena);
+
/* Adds unknown data (serialized protobuf data) to the given message. The data
* is copied into the message instance. */
void upb_Message_AddUnknown(upb_Message* msg, const char* data, size_t len,
@@ -524,6 +527,9 @@
/* Returns a reference to the message's unknown data. */
const char* upb_Message_GetUnknown(const upb_Message* msg, size_t* len);
+/* Removes partial unknown data from message. */
+void upb_Message_DeleteUnknown(upb_Message* msg, const char* data, size_t len);
+
/* Returns the number of extensions present in this message. */
size_t upb_Message_ExtensionCount(const upb_Message* msg);
@@ -1172,28 +1178,23 @@
*/
typedef struct upb_ExtensionRegistry upb_ExtensionRegistry;
+typedef struct upb_MiniTable_Extension upb_MiniTable_Extension;
// Creates a upb_ExtensionRegistry in the given arena.
// The arena must outlive any use of the extreg.
upb_ExtensionRegistry* upb_ExtensionRegistry_New(upb_Arena* arena);
-// EVERYTHING BELOW THIS LINE IS INTERNAL - DO NOT USE /////////////////////////
+// Adds the given extension info for the array |e| of size |count| into the
+// registry. If there are any errors, the entire array is backed out.
+// The extensions must outlive the registry.
+bool upb_ExtensionRegistry_AddArray(upb_ExtensionRegistry* r,
+ const upb_MiniTable_Extension** e,
+ size_t count);
-typedef struct upb_MiniTable upb_MiniTable;
-typedef struct upb_MiniTable_Extension upb_MiniTable_Extension;
-
-// Adds the given extension info for message type |l| and field number |num|
-// into the registry. Returns false if this message type and field number were
-// already in the map, or if memory allocation fails.
-bool _upb_extreg_add(upb_ExtensionRegistry* r,
- const upb_MiniTable_Extension** e, size_t count);
-
-// Looks up the extension (if any) defined for message type |l| and field
-// number |num|. If an extension was found, copies the field info into |*ext|
-// and returns true. Otherwise returns false.
-const upb_MiniTable_Extension* _upb_extreg_get(const upb_ExtensionRegistry* r,
- const upb_MiniTable* l,
- uint32_t num);
+// Looks up the extension (if any) defined for message type |t| and field
+// number |num|. Returns the extension if found, otherwise NULL.
+const upb_MiniTable_Extension* upb_ExtensionRegistry_Lookup(
+ const upb_ExtensionRegistry* r, const upb_MiniTable* t, uint32_t num);
#ifdef __cplusplus
} /* extern "C" */
@@ -1609,6 +1610,12 @@
typedef enum {
kUpb_LabelFlags_IsPacked = 4,
kUpb_LabelFlags_IsExtension = 8,
+ // Indicates that this descriptor type is an "alternate type":
+ // - for Int32, this indicates that the actual type is Enum (but was
+ // rewritten to Int32 because it is an open enum that requires no check).
+ // - for Bytes, this indicates that the actual type is String (but does
+ // not require any UTF-8 check).
+ kUpb_LabelFlags_IsAlternate = 16,
} upb_LabelFlags;
// Note: we sort by this number when calculating layout order.
@@ -1616,10 +1623,9 @@
kUpb_FieldRep_1Byte = 0,
kUpb_FieldRep_4Byte = 1,
kUpb_FieldRep_StringView = 2,
- kUpb_FieldRep_Pointer = 3,
- kUpb_FieldRep_8Byte = 4,
+ kUpb_FieldRep_8Byte = 3,
- kUpb_FieldRep_Shift = 5, // Bit offset of the rep in upb_MiniTable_Field.mode
+ kUpb_FieldRep_Shift = 6, // Bit offset of the rep in upb_MiniTable_Field.mode
kUpb_FieldRep_Max = kUpb_FieldRep_8Byte,
} upb_FieldRep;
@@ -1739,8 +1745,6 @@
_upb_FastTable_Entry fasttable[];
};
-typedef struct upb_MiniTable_Extension upb_MiniTable_Extension;
-
struct upb_MiniTable_Extension {
upb_MiniTable_Field field;
const upb_MiniTable* extendee;
@@ -1811,20 +1815,17 @@
return l->size + sizeof(upb_Message_Internal);
}
-UPB_INLINE upb_Message* _upb_Message_New_inl(const upb_MiniTable* l,
- upb_Arena* a) {
- size_t size = upb_msg_sizeof(l);
- void* mem = upb_Arena_Malloc(a, size + sizeof(upb_Message_Internal));
- upb_Message* msg;
+/* Inline version upb_Message_New(), for internal use */
+UPB_INLINE upb_Message* _upb_Message_New(const upb_MiniTable* mini_table,
+ upb_Arena* arena) {
+ size_t size = upb_msg_sizeof(mini_table);
+ void* mem = upb_Arena_Malloc(arena, size + sizeof(upb_Message_Internal));
if (UPB_UNLIKELY(!mem)) return NULL;
- msg = UPB_PTR_AT(mem, sizeof(upb_Message_Internal), upb_Message);
+ upb_Message* msg = UPB_PTR_AT(mem, sizeof(upb_Message_Internal), upb_Message);
memset(mem, 0, size);
return msg;
}
-/* Creates a new messages with the given layout on the given arena. */
-upb_Message* _upb_Message_New(const upb_MiniTable* l, upb_Arena* a);
-
UPB_INLINE upb_Message_Internal* upb_Message_Getinternal(upb_Message* msg) {
ptrdiff_t size = sizeof(upb_Message_Internal);
return (upb_Message_Internal*)((char*)msg - size);
@@ -1879,9 +1880,6 @@
void _upb_Message_Clearext(upb_Message* msg,
const upb_MiniTable_Extension* ext);
-void _upb_Message_Clearext(upb_Message* msg,
- const upb_MiniTable_Extension* ext);
-
/** Hasbit access *************************************************************/
UPB_INLINE bool _upb_hasbit(const upb_Message* msg, size_t idx) {
@@ -2659,95 +2657,95 @@
return _upb_hasbit(msg, 1);
}
UPB_INLINE void google_protobuf_FileDescriptorProto_clear_name(const google_protobuf_FileDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(40, 8), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 1);
}
UPB_INLINE upb_StringView google_protobuf_FileDescriptorProto_name(const google_protobuf_FileDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(40, 8), upb_StringView);
}
UPB_INLINE bool google_protobuf_FileDescriptorProto_has_package(const google_protobuf_FileDescriptorProto* msg) {
return _upb_hasbit(msg, 2);
}
UPB_INLINE void google_protobuf_FileDescriptorProto_clear_package(const google_protobuf_FileDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(12, 24), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(48, 24), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 2);
}
UPB_INLINE upb_StringView google_protobuf_FileDescriptorProto_package(const google_protobuf_FileDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(12, 24), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(48, 24), upb_StringView);
}
UPB_INLINE void google_protobuf_FileDescriptorProto_clear_dependency(const google_protobuf_FileDescriptorProto* msg) {
- _upb_array_detach(msg, UPB_SIZE(20, 40));
+ _upb_array_detach(msg, UPB_SIZE(4, 40));
}
UPB_INLINE upb_StringView const* google_protobuf_FileDescriptorProto_dependency(const google_protobuf_FileDescriptorProto* msg, size_t* len) {
- return (upb_StringView const*)_upb_array_accessor(msg, UPB_SIZE(20, 40), len);
+ return (upb_StringView const*)_upb_array_accessor(msg, UPB_SIZE(4, 40), len);
}
UPB_INLINE bool google_protobuf_FileDescriptorProto_has_message_type(const google_protobuf_FileDescriptorProto* msg) {
- return _upb_has_submsg_nohasbit(msg, UPB_SIZE(24, 48));
+ return _upb_has_submsg_nohasbit(msg, UPB_SIZE(8, 48));
}
UPB_INLINE void google_protobuf_FileDescriptorProto_clear_message_type(const google_protobuf_FileDescriptorProto* msg) {
- _upb_array_detach(msg, UPB_SIZE(24, 48));
+ _upb_array_detach(msg, UPB_SIZE(8, 48));
}
UPB_INLINE const google_protobuf_DescriptorProto* const* google_protobuf_FileDescriptorProto_message_type(const google_protobuf_FileDescriptorProto* msg, size_t* len) {
- return (const google_protobuf_DescriptorProto* const*)_upb_array_accessor(msg, UPB_SIZE(24, 48), len);
+ return (const google_protobuf_DescriptorProto* const*)_upb_array_accessor(msg, UPB_SIZE(8, 48), len);
}
UPB_INLINE bool google_protobuf_FileDescriptorProto_has_enum_type(const google_protobuf_FileDescriptorProto* msg) {
- return _upb_has_submsg_nohasbit(msg, UPB_SIZE(28, 56));
+ return _upb_has_submsg_nohasbit(msg, UPB_SIZE(12, 56));
}
UPB_INLINE void google_protobuf_FileDescriptorProto_clear_enum_type(const google_protobuf_FileDescriptorProto* msg) {
- _upb_array_detach(msg, UPB_SIZE(28, 56));
+ _upb_array_detach(msg, UPB_SIZE(12, 56));
}
UPB_INLINE const google_protobuf_EnumDescriptorProto* const* google_protobuf_FileDescriptorProto_enum_type(const google_protobuf_FileDescriptorProto* msg, size_t* len) {
- return (const google_protobuf_EnumDescriptorProto* const*)_upb_array_accessor(msg, UPB_SIZE(28, 56), len);
+ return (const google_protobuf_EnumDescriptorProto* const*)_upb_array_accessor(msg, UPB_SIZE(12, 56), len);
}
UPB_INLINE bool google_protobuf_FileDescriptorProto_has_service(const google_protobuf_FileDescriptorProto* msg) {
- return _upb_has_submsg_nohasbit(msg, UPB_SIZE(32, 64));
+ return _upb_has_submsg_nohasbit(msg, UPB_SIZE(16, 64));
}
UPB_INLINE void google_protobuf_FileDescriptorProto_clear_service(const google_protobuf_FileDescriptorProto* msg) {
- _upb_array_detach(msg, UPB_SIZE(32, 64));
+ _upb_array_detach(msg, UPB_SIZE(16, 64));
}
UPB_INLINE const google_protobuf_ServiceDescriptorProto* const* google_protobuf_FileDescriptorProto_service(const google_protobuf_FileDescriptorProto* msg, size_t* len) {
- return (const google_protobuf_ServiceDescriptorProto* const*)_upb_array_accessor(msg, UPB_SIZE(32, 64), len);
+ return (const google_protobuf_ServiceDescriptorProto* const*)_upb_array_accessor(msg, UPB_SIZE(16, 64), len);
}
UPB_INLINE bool google_protobuf_FileDescriptorProto_has_extension(const google_protobuf_FileDescriptorProto* msg) {
- return _upb_has_submsg_nohasbit(msg, UPB_SIZE(36, 72));
+ return _upb_has_submsg_nohasbit(msg, UPB_SIZE(20, 72));
}
UPB_INLINE void google_protobuf_FileDescriptorProto_clear_extension(const google_protobuf_FileDescriptorProto* msg) {
- _upb_array_detach(msg, UPB_SIZE(36, 72));
+ _upb_array_detach(msg, UPB_SIZE(20, 72));
}
UPB_INLINE const google_protobuf_FieldDescriptorProto* const* google_protobuf_FileDescriptorProto_extension(const google_protobuf_FileDescriptorProto* msg, size_t* len) {
- return (const google_protobuf_FieldDescriptorProto* const*)_upb_array_accessor(msg, UPB_SIZE(36, 72), len);
+ return (const google_protobuf_FieldDescriptorProto* const*)_upb_array_accessor(msg, UPB_SIZE(20, 72), len);
}
UPB_INLINE bool google_protobuf_FileDescriptorProto_has_options(const google_protobuf_FileDescriptorProto* msg) {
return _upb_hasbit(msg, 3);
}
UPB_INLINE void google_protobuf_FileDescriptorProto_clear_options(const google_protobuf_FileDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(40, 80), const upb_Message*) = NULL;
+ *UPB_PTR_AT(msg, UPB_SIZE(24, 80), const upb_Message*) = NULL;
_upb_clearhas(msg, 3);
}
UPB_INLINE const google_protobuf_FileOptions* google_protobuf_FileDescriptorProto_options(const google_protobuf_FileDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(40, 80), const google_protobuf_FileOptions*);
+ return *UPB_PTR_AT(msg, UPB_SIZE(24, 80), const google_protobuf_FileOptions*);
}
UPB_INLINE bool google_protobuf_FileDescriptorProto_has_source_code_info(const google_protobuf_FileDescriptorProto* msg) {
return _upb_hasbit(msg, 4);
}
UPB_INLINE void google_protobuf_FileDescriptorProto_clear_source_code_info(const google_protobuf_FileDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(44, 88), const upb_Message*) = NULL;
+ *UPB_PTR_AT(msg, UPB_SIZE(28, 88), const upb_Message*) = NULL;
_upb_clearhas(msg, 4);
}
UPB_INLINE const google_protobuf_SourceCodeInfo* google_protobuf_FileDescriptorProto_source_code_info(const google_protobuf_FileDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(44, 88), const google_protobuf_SourceCodeInfo*);
+ return *UPB_PTR_AT(msg, UPB_SIZE(28, 88), const google_protobuf_SourceCodeInfo*);
}
UPB_INLINE void google_protobuf_FileDescriptorProto_clear_public_dependency(const google_protobuf_FileDescriptorProto* msg) {
- _upb_array_detach(msg, UPB_SIZE(48, 96));
+ _upb_array_detach(msg, UPB_SIZE(32, 96));
}
UPB_INLINE int32_t const* google_protobuf_FileDescriptorProto_public_dependency(const google_protobuf_FileDescriptorProto* msg, size_t* len) {
- return (int32_t const*)_upb_array_accessor(msg, UPB_SIZE(48, 96), len);
+ return (int32_t const*)_upb_array_accessor(msg, UPB_SIZE(32, 96), len);
}
UPB_INLINE void google_protobuf_FileDescriptorProto_clear_weak_dependency(const google_protobuf_FileDescriptorProto* msg) {
- _upb_array_detach(msg, UPB_SIZE(52, 104));
+ _upb_array_detach(msg, UPB_SIZE(36, 104));
}
UPB_INLINE int32_t const* google_protobuf_FileDescriptorProto_weak_dependency(const google_protobuf_FileDescriptorProto* msg, size_t* len) {
- return (int32_t const*)_upb_array_accessor(msg, UPB_SIZE(52, 104), len);
+ return (int32_t const*)_upb_array_accessor(msg, UPB_SIZE(36, 104), len);
}
UPB_INLINE bool google_protobuf_FileDescriptorProto_has_syntax(const google_protobuf_FileDescriptorProto* msg) {
return _upb_hasbit(msg, 5);
@@ -2772,72 +2770,72 @@
UPB_INLINE void google_protobuf_FileDescriptorProto_set_name(google_protobuf_FileDescriptorProto *msg, upb_StringView value) {
_upb_sethas(msg, 1);
- *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(40, 8), upb_StringView) = value;
}
UPB_INLINE void google_protobuf_FileDescriptorProto_set_package(google_protobuf_FileDescriptorProto *msg, upb_StringView value) {
_upb_sethas(msg, 2);
- *UPB_PTR_AT(msg, UPB_SIZE(12, 24), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(48, 24), upb_StringView) = value;
}
UPB_INLINE upb_StringView* google_protobuf_FileDescriptorProto_mutable_dependency(google_protobuf_FileDescriptorProto* msg, size_t* len) {
- return (upb_StringView*)_upb_array_mutable_accessor(msg, UPB_SIZE(20, 40), len);
+ return (upb_StringView*)_upb_array_mutable_accessor(msg, UPB_SIZE(4, 40), len);
}
UPB_INLINE upb_StringView* google_protobuf_FileDescriptorProto_resize_dependency(google_protobuf_FileDescriptorProto* msg, size_t len, upb_Arena* arena) {
- return (upb_StringView*)_upb_Array_Resize_accessor2(msg, UPB_SIZE(20, 40), len, UPB_SIZE(3, 4), arena);
+ return (upb_StringView*)_upb_Array_Resize_accessor2(msg, UPB_SIZE(4, 40), len, UPB_SIZE(3, 4), arena);
}
UPB_INLINE bool google_protobuf_FileDescriptorProto_add_dependency(google_protobuf_FileDescriptorProto* msg, upb_StringView val, upb_Arena* arena) {
- return _upb_Array_Append_accessor2(msg, UPB_SIZE(20, 40), UPB_SIZE(3, 4), &val, arena);
+ return _upb_Array_Append_accessor2(msg, UPB_SIZE(4, 40), UPB_SIZE(3, 4), &val, arena);
}
UPB_INLINE google_protobuf_DescriptorProto** google_protobuf_FileDescriptorProto_mutable_message_type(google_protobuf_FileDescriptorProto* msg, size_t* len) {
- return (google_protobuf_DescriptorProto**)_upb_array_mutable_accessor(msg, UPB_SIZE(24, 48), len);
+ return (google_protobuf_DescriptorProto**)_upb_array_mutable_accessor(msg, UPB_SIZE(8, 48), len);
}
UPB_INLINE google_protobuf_DescriptorProto** google_protobuf_FileDescriptorProto_resize_message_type(google_protobuf_FileDescriptorProto* msg, size_t len, upb_Arena* arena) {
- return (google_protobuf_DescriptorProto**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(24, 48), len, UPB_SIZE(2, 3), arena);
+ return (google_protobuf_DescriptorProto**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(8, 48), len, UPB_SIZE(2, 3), arena);
}
UPB_INLINE struct google_protobuf_DescriptorProto* google_protobuf_FileDescriptorProto_add_message_type(google_protobuf_FileDescriptorProto* msg, upb_Arena* arena) {
struct google_protobuf_DescriptorProto* sub = (struct google_protobuf_DescriptorProto*)_upb_Message_New(&google_protobuf_DescriptorProto_msg_init, arena);
- bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(24, 48), UPB_SIZE(2, 3), &sub, arena);
+ bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(8, 48), UPB_SIZE(2, 3), &sub, arena);
if (!ok) return NULL;
return sub;
}
UPB_INLINE google_protobuf_EnumDescriptorProto** google_protobuf_FileDescriptorProto_mutable_enum_type(google_protobuf_FileDescriptorProto* msg, size_t* len) {
- return (google_protobuf_EnumDescriptorProto**)_upb_array_mutable_accessor(msg, UPB_SIZE(28, 56), len);
+ return (google_protobuf_EnumDescriptorProto**)_upb_array_mutable_accessor(msg, UPB_SIZE(12, 56), len);
}
UPB_INLINE google_protobuf_EnumDescriptorProto** google_protobuf_FileDescriptorProto_resize_enum_type(google_protobuf_FileDescriptorProto* msg, size_t len, upb_Arena* arena) {
- return (google_protobuf_EnumDescriptorProto**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(28, 56), len, UPB_SIZE(2, 3), arena);
+ return (google_protobuf_EnumDescriptorProto**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(12, 56), len, UPB_SIZE(2, 3), arena);
}
UPB_INLINE struct google_protobuf_EnumDescriptorProto* google_protobuf_FileDescriptorProto_add_enum_type(google_protobuf_FileDescriptorProto* msg, upb_Arena* arena) {
struct google_protobuf_EnumDescriptorProto* sub = (struct google_protobuf_EnumDescriptorProto*)_upb_Message_New(&google_protobuf_EnumDescriptorProto_msg_init, arena);
- bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(28, 56), UPB_SIZE(2, 3), &sub, arena);
+ bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(12, 56), UPB_SIZE(2, 3), &sub, arena);
if (!ok) return NULL;
return sub;
}
UPB_INLINE google_protobuf_ServiceDescriptorProto** google_protobuf_FileDescriptorProto_mutable_service(google_protobuf_FileDescriptorProto* msg, size_t* len) {
- return (google_protobuf_ServiceDescriptorProto**)_upb_array_mutable_accessor(msg, UPB_SIZE(32, 64), len);
+ return (google_protobuf_ServiceDescriptorProto**)_upb_array_mutable_accessor(msg, UPB_SIZE(16, 64), len);
}
UPB_INLINE google_protobuf_ServiceDescriptorProto** google_protobuf_FileDescriptorProto_resize_service(google_protobuf_FileDescriptorProto* msg, size_t len, upb_Arena* arena) {
- return (google_protobuf_ServiceDescriptorProto**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(32, 64), len, UPB_SIZE(2, 3), arena);
+ return (google_protobuf_ServiceDescriptorProto**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(16, 64), len, UPB_SIZE(2, 3), arena);
}
UPB_INLINE struct google_protobuf_ServiceDescriptorProto* google_protobuf_FileDescriptorProto_add_service(google_protobuf_FileDescriptorProto* msg, upb_Arena* arena) {
struct google_protobuf_ServiceDescriptorProto* sub = (struct google_protobuf_ServiceDescriptorProto*)_upb_Message_New(&google_protobuf_ServiceDescriptorProto_msg_init, arena);
- bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(32, 64), UPB_SIZE(2, 3), &sub, arena);
+ bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(16, 64), UPB_SIZE(2, 3), &sub, arena);
if (!ok) return NULL;
return sub;
}
UPB_INLINE google_protobuf_FieldDescriptorProto** google_protobuf_FileDescriptorProto_mutable_extension(google_protobuf_FileDescriptorProto* msg, size_t* len) {
- return (google_protobuf_FieldDescriptorProto**)_upb_array_mutable_accessor(msg, UPB_SIZE(36, 72), len);
+ return (google_protobuf_FieldDescriptorProto**)_upb_array_mutable_accessor(msg, UPB_SIZE(20, 72), len);
}
UPB_INLINE google_protobuf_FieldDescriptorProto** google_protobuf_FileDescriptorProto_resize_extension(google_protobuf_FileDescriptorProto* msg, size_t len, upb_Arena* arena) {
- return (google_protobuf_FieldDescriptorProto**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(36, 72), len, UPB_SIZE(2, 3), arena);
+ return (google_protobuf_FieldDescriptorProto**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(20, 72), len, UPB_SIZE(2, 3), arena);
}
UPB_INLINE struct google_protobuf_FieldDescriptorProto* google_protobuf_FileDescriptorProto_add_extension(google_protobuf_FileDescriptorProto* msg, upb_Arena* arena) {
struct google_protobuf_FieldDescriptorProto* sub = (struct google_protobuf_FieldDescriptorProto*)_upb_Message_New(&google_protobuf_FieldDescriptorProto_msg_init, arena);
- bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(36, 72), UPB_SIZE(2, 3), &sub, arena);
+ bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(20, 72), UPB_SIZE(2, 3), &sub, arena);
if (!ok) return NULL;
return sub;
}
UPB_INLINE void google_protobuf_FileDescriptorProto_set_options(google_protobuf_FileDescriptorProto *msg, google_protobuf_FileOptions* value) {
_upb_sethas(msg, 3);
- *UPB_PTR_AT(msg, UPB_SIZE(40, 80), google_protobuf_FileOptions*) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(24, 80), google_protobuf_FileOptions*) = value;
}
UPB_INLINE struct google_protobuf_FileOptions* google_protobuf_FileDescriptorProto_mutable_options(google_protobuf_FileDescriptorProto* msg, upb_Arena* arena) {
struct google_protobuf_FileOptions* sub = (struct google_protobuf_FileOptions*)google_protobuf_FileDescriptorProto_options(msg);
@@ -2850,7 +2848,7 @@
}
UPB_INLINE void google_protobuf_FileDescriptorProto_set_source_code_info(google_protobuf_FileDescriptorProto *msg, google_protobuf_SourceCodeInfo* value) {
_upb_sethas(msg, 4);
- *UPB_PTR_AT(msg, UPB_SIZE(44, 88), google_protobuf_SourceCodeInfo*) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(28, 88), google_protobuf_SourceCodeInfo*) = value;
}
UPB_INLINE struct google_protobuf_SourceCodeInfo* google_protobuf_FileDescriptorProto_mutable_source_code_info(google_protobuf_FileDescriptorProto* msg, upb_Arena* arena) {
struct google_protobuf_SourceCodeInfo* sub = (struct google_protobuf_SourceCodeInfo*)google_protobuf_FileDescriptorProto_source_code_info(msg);
@@ -2862,22 +2860,22 @@
return sub;
}
UPB_INLINE int32_t* google_protobuf_FileDescriptorProto_mutable_public_dependency(google_protobuf_FileDescriptorProto* msg, size_t* len) {
- return (int32_t*)_upb_array_mutable_accessor(msg, UPB_SIZE(48, 96), len);
+ return (int32_t*)_upb_array_mutable_accessor(msg, UPB_SIZE(32, 96), len);
}
UPB_INLINE int32_t* google_protobuf_FileDescriptorProto_resize_public_dependency(google_protobuf_FileDescriptorProto* msg, size_t len, upb_Arena* arena) {
- return (int32_t*)_upb_Array_Resize_accessor2(msg, UPB_SIZE(48, 96), len, 2, arena);
+ return (int32_t*)_upb_Array_Resize_accessor2(msg, UPB_SIZE(32, 96), len, 2, arena);
}
UPB_INLINE bool google_protobuf_FileDescriptorProto_add_public_dependency(google_protobuf_FileDescriptorProto* msg, int32_t val, upb_Arena* arena) {
- return _upb_Array_Append_accessor2(msg, UPB_SIZE(48, 96), 2, &val, arena);
+ return _upb_Array_Append_accessor2(msg, UPB_SIZE(32, 96), 2, &val, arena);
}
UPB_INLINE int32_t* google_protobuf_FileDescriptorProto_mutable_weak_dependency(google_protobuf_FileDescriptorProto* msg, size_t* len) {
- return (int32_t*)_upb_array_mutable_accessor(msg, UPB_SIZE(52, 104), len);
+ return (int32_t*)_upb_array_mutable_accessor(msg, UPB_SIZE(36, 104), len);
}
UPB_INLINE int32_t* google_protobuf_FileDescriptorProto_resize_weak_dependency(google_protobuf_FileDescriptorProto* msg, size_t len, upb_Arena* arena) {
- return (int32_t*)_upb_Array_Resize_accessor2(msg, UPB_SIZE(52, 104), len, 2, arena);
+ return (int32_t*)_upb_Array_Resize_accessor2(msg, UPB_SIZE(36, 104), len, 2, arena);
}
UPB_INLINE bool google_protobuf_FileDescriptorProto_add_weak_dependency(google_protobuf_FileDescriptorProto* msg, int32_t val, upb_Arena* arena) {
- return _upb_Array_Append_accessor2(msg, UPB_SIZE(52, 104), 2, &val, arena);
+ return _upb_Array_Append_accessor2(msg, UPB_SIZE(36, 104), 2, &val, arena);
}
UPB_INLINE void google_protobuf_FileDescriptorProto_set_syntax(google_protobuf_FileDescriptorProto *msg, upb_StringView value) {
_upb_sethas(msg, 5);
@@ -2927,159 +2925,159 @@
return _upb_hasbit(msg, 1);
}
UPB_INLINE void google_protobuf_DescriptorProto_clear_name(const google_protobuf_DescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(40, 8), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 1);
}
UPB_INLINE upb_StringView google_protobuf_DescriptorProto_name(const google_protobuf_DescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(40, 8), upb_StringView);
}
UPB_INLINE bool google_protobuf_DescriptorProto_has_field(const google_protobuf_DescriptorProto* msg) {
- return _upb_has_submsg_nohasbit(msg, UPB_SIZE(12, 24));
+ return _upb_has_submsg_nohasbit(msg, UPB_SIZE(4, 24));
}
UPB_INLINE void google_protobuf_DescriptorProto_clear_field(const google_protobuf_DescriptorProto* msg) {
- _upb_array_detach(msg, UPB_SIZE(12, 24));
+ _upb_array_detach(msg, UPB_SIZE(4, 24));
}
UPB_INLINE const google_protobuf_FieldDescriptorProto* const* google_protobuf_DescriptorProto_field(const google_protobuf_DescriptorProto* msg, size_t* len) {
- return (const google_protobuf_FieldDescriptorProto* const*)_upb_array_accessor(msg, UPB_SIZE(12, 24), len);
+ return (const google_protobuf_FieldDescriptorProto* const*)_upb_array_accessor(msg, UPB_SIZE(4, 24), len);
}
UPB_INLINE bool google_protobuf_DescriptorProto_has_nested_type(const google_protobuf_DescriptorProto* msg) {
- return _upb_has_submsg_nohasbit(msg, UPB_SIZE(16, 32));
+ return _upb_has_submsg_nohasbit(msg, UPB_SIZE(8, 32));
}
UPB_INLINE void google_protobuf_DescriptorProto_clear_nested_type(const google_protobuf_DescriptorProto* msg) {
- _upb_array_detach(msg, UPB_SIZE(16, 32));
+ _upb_array_detach(msg, UPB_SIZE(8, 32));
}
UPB_INLINE const google_protobuf_DescriptorProto* const* google_protobuf_DescriptorProto_nested_type(const google_protobuf_DescriptorProto* msg, size_t* len) {
- return (const google_protobuf_DescriptorProto* const*)_upb_array_accessor(msg, UPB_SIZE(16, 32), len);
+ return (const google_protobuf_DescriptorProto* const*)_upb_array_accessor(msg, UPB_SIZE(8, 32), len);
}
UPB_INLINE bool google_protobuf_DescriptorProto_has_enum_type(const google_protobuf_DescriptorProto* msg) {
- return _upb_has_submsg_nohasbit(msg, UPB_SIZE(20, 40));
+ return _upb_has_submsg_nohasbit(msg, UPB_SIZE(12, 40));
}
UPB_INLINE void google_protobuf_DescriptorProto_clear_enum_type(const google_protobuf_DescriptorProto* msg) {
- _upb_array_detach(msg, UPB_SIZE(20, 40));
+ _upb_array_detach(msg, UPB_SIZE(12, 40));
}
UPB_INLINE const google_protobuf_EnumDescriptorProto* const* google_protobuf_DescriptorProto_enum_type(const google_protobuf_DescriptorProto* msg, size_t* len) {
- return (const google_protobuf_EnumDescriptorProto* const*)_upb_array_accessor(msg, UPB_SIZE(20, 40), len);
+ return (const google_protobuf_EnumDescriptorProto* const*)_upb_array_accessor(msg, UPB_SIZE(12, 40), len);
}
UPB_INLINE bool google_protobuf_DescriptorProto_has_extension_range(const google_protobuf_DescriptorProto* msg) {
- return _upb_has_submsg_nohasbit(msg, UPB_SIZE(24, 48));
+ return _upb_has_submsg_nohasbit(msg, UPB_SIZE(16, 48));
}
UPB_INLINE void google_protobuf_DescriptorProto_clear_extension_range(const google_protobuf_DescriptorProto* msg) {
- _upb_array_detach(msg, UPB_SIZE(24, 48));
+ _upb_array_detach(msg, UPB_SIZE(16, 48));
}
UPB_INLINE const google_protobuf_DescriptorProto_ExtensionRange* const* google_protobuf_DescriptorProto_extension_range(const google_protobuf_DescriptorProto* msg, size_t* len) {
- return (const google_protobuf_DescriptorProto_ExtensionRange* const*)_upb_array_accessor(msg, UPB_SIZE(24, 48), len);
+ return (const google_protobuf_DescriptorProto_ExtensionRange* const*)_upb_array_accessor(msg, UPB_SIZE(16, 48), len);
}
UPB_INLINE bool google_protobuf_DescriptorProto_has_extension(const google_protobuf_DescriptorProto* msg) {
- return _upb_has_submsg_nohasbit(msg, UPB_SIZE(28, 56));
+ return _upb_has_submsg_nohasbit(msg, UPB_SIZE(20, 56));
}
UPB_INLINE void google_protobuf_DescriptorProto_clear_extension(const google_protobuf_DescriptorProto* msg) {
- _upb_array_detach(msg, UPB_SIZE(28, 56));
+ _upb_array_detach(msg, UPB_SIZE(20, 56));
}
UPB_INLINE const google_protobuf_FieldDescriptorProto* const* google_protobuf_DescriptorProto_extension(const google_protobuf_DescriptorProto* msg, size_t* len) {
- return (const google_protobuf_FieldDescriptorProto* const*)_upb_array_accessor(msg, UPB_SIZE(28, 56), len);
+ return (const google_protobuf_FieldDescriptorProto* const*)_upb_array_accessor(msg, UPB_SIZE(20, 56), len);
}
UPB_INLINE bool google_protobuf_DescriptorProto_has_options(const google_protobuf_DescriptorProto* msg) {
return _upb_hasbit(msg, 2);
}
UPB_INLINE void google_protobuf_DescriptorProto_clear_options(const google_protobuf_DescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(32, 64), const upb_Message*) = NULL;
+ *UPB_PTR_AT(msg, UPB_SIZE(24, 64), const upb_Message*) = NULL;
_upb_clearhas(msg, 2);
}
UPB_INLINE const google_protobuf_MessageOptions* google_protobuf_DescriptorProto_options(const google_protobuf_DescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(32, 64), const google_protobuf_MessageOptions*);
+ return *UPB_PTR_AT(msg, UPB_SIZE(24, 64), const google_protobuf_MessageOptions*);
}
UPB_INLINE bool google_protobuf_DescriptorProto_has_oneof_decl(const google_protobuf_DescriptorProto* msg) {
- return _upb_has_submsg_nohasbit(msg, UPB_SIZE(36, 72));
+ return _upb_has_submsg_nohasbit(msg, UPB_SIZE(28, 72));
}
UPB_INLINE void google_protobuf_DescriptorProto_clear_oneof_decl(const google_protobuf_DescriptorProto* msg) {
- _upb_array_detach(msg, UPB_SIZE(36, 72));
+ _upb_array_detach(msg, UPB_SIZE(28, 72));
}
UPB_INLINE const google_protobuf_OneofDescriptorProto* const* google_protobuf_DescriptorProto_oneof_decl(const google_protobuf_DescriptorProto* msg, size_t* len) {
- return (const google_protobuf_OneofDescriptorProto* const*)_upb_array_accessor(msg, UPB_SIZE(36, 72), len);
+ return (const google_protobuf_OneofDescriptorProto* const*)_upb_array_accessor(msg, UPB_SIZE(28, 72), len);
}
UPB_INLINE bool google_protobuf_DescriptorProto_has_reserved_range(const google_protobuf_DescriptorProto* msg) {
- return _upb_has_submsg_nohasbit(msg, UPB_SIZE(40, 80));
+ return _upb_has_submsg_nohasbit(msg, UPB_SIZE(32, 80));
}
UPB_INLINE void google_protobuf_DescriptorProto_clear_reserved_range(const google_protobuf_DescriptorProto* msg) {
- _upb_array_detach(msg, UPB_SIZE(40, 80));
+ _upb_array_detach(msg, UPB_SIZE(32, 80));
}
UPB_INLINE const google_protobuf_DescriptorProto_ReservedRange* const* google_protobuf_DescriptorProto_reserved_range(const google_protobuf_DescriptorProto* msg, size_t* len) {
- return (const google_protobuf_DescriptorProto_ReservedRange* const*)_upb_array_accessor(msg, UPB_SIZE(40, 80), len);
+ return (const google_protobuf_DescriptorProto_ReservedRange* const*)_upb_array_accessor(msg, UPB_SIZE(32, 80), len);
}
UPB_INLINE void google_protobuf_DescriptorProto_clear_reserved_name(const google_protobuf_DescriptorProto* msg) {
- _upb_array_detach(msg, UPB_SIZE(44, 88));
+ _upb_array_detach(msg, UPB_SIZE(36, 88));
}
UPB_INLINE upb_StringView const* google_protobuf_DescriptorProto_reserved_name(const google_protobuf_DescriptorProto* msg, size_t* len) {
- return (upb_StringView const*)_upb_array_accessor(msg, UPB_SIZE(44, 88), len);
+ return (upb_StringView const*)_upb_array_accessor(msg, UPB_SIZE(36, 88), len);
}
UPB_INLINE void google_protobuf_DescriptorProto_set_name(google_protobuf_DescriptorProto *msg, upb_StringView value) {
_upb_sethas(msg, 1);
- *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(40, 8), upb_StringView) = value;
}
UPB_INLINE google_protobuf_FieldDescriptorProto** google_protobuf_DescriptorProto_mutable_field(google_protobuf_DescriptorProto* msg, size_t* len) {
- return (google_protobuf_FieldDescriptorProto**)_upb_array_mutable_accessor(msg, UPB_SIZE(12, 24), len);
+ return (google_protobuf_FieldDescriptorProto**)_upb_array_mutable_accessor(msg, UPB_SIZE(4, 24), len);
}
UPB_INLINE google_protobuf_FieldDescriptorProto** google_protobuf_DescriptorProto_resize_field(google_protobuf_DescriptorProto* msg, size_t len, upb_Arena* arena) {
- return (google_protobuf_FieldDescriptorProto**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(12, 24), len, UPB_SIZE(2, 3), arena);
+ return (google_protobuf_FieldDescriptorProto**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(4, 24), len, UPB_SIZE(2, 3), arena);
}
UPB_INLINE struct google_protobuf_FieldDescriptorProto* google_protobuf_DescriptorProto_add_field(google_protobuf_DescriptorProto* msg, upb_Arena* arena) {
struct google_protobuf_FieldDescriptorProto* sub = (struct google_protobuf_FieldDescriptorProto*)_upb_Message_New(&google_protobuf_FieldDescriptorProto_msg_init, arena);
- bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(12, 24), UPB_SIZE(2, 3), &sub, arena);
+ bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(4, 24), UPB_SIZE(2, 3), &sub, arena);
if (!ok) return NULL;
return sub;
}
UPB_INLINE google_protobuf_DescriptorProto** google_protobuf_DescriptorProto_mutable_nested_type(google_protobuf_DescriptorProto* msg, size_t* len) {
- return (google_protobuf_DescriptorProto**)_upb_array_mutable_accessor(msg, UPB_SIZE(16, 32), len);
+ return (google_protobuf_DescriptorProto**)_upb_array_mutable_accessor(msg, UPB_SIZE(8, 32), len);
}
UPB_INLINE google_protobuf_DescriptorProto** google_protobuf_DescriptorProto_resize_nested_type(google_protobuf_DescriptorProto* msg, size_t len, upb_Arena* arena) {
- return (google_protobuf_DescriptorProto**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(16, 32), len, UPB_SIZE(2, 3), arena);
+ return (google_protobuf_DescriptorProto**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(8, 32), len, UPB_SIZE(2, 3), arena);
}
UPB_INLINE struct google_protobuf_DescriptorProto* google_protobuf_DescriptorProto_add_nested_type(google_protobuf_DescriptorProto* msg, upb_Arena* arena) {
struct google_protobuf_DescriptorProto* sub = (struct google_protobuf_DescriptorProto*)_upb_Message_New(&google_protobuf_DescriptorProto_msg_init, arena);
- bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(16, 32), UPB_SIZE(2, 3), &sub, arena);
+ bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(8, 32), UPB_SIZE(2, 3), &sub, arena);
if (!ok) return NULL;
return sub;
}
UPB_INLINE google_protobuf_EnumDescriptorProto** google_protobuf_DescriptorProto_mutable_enum_type(google_protobuf_DescriptorProto* msg, size_t* len) {
- return (google_protobuf_EnumDescriptorProto**)_upb_array_mutable_accessor(msg, UPB_SIZE(20, 40), len);
+ return (google_protobuf_EnumDescriptorProto**)_upb_array_mutable_accessor(msg, UPB_SIZE(12, 40), len);
}
UPB_INLINE google_protobuf_EnumDescriptorProto** google_protobuf_DescriptorProto_resize_enum_type(google_protobuf_DescriptorProto* msg, size_t len, upb_Arena* arena) {
- return (google_protobuf_EnumDescriptorProto**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(20, 40), len, UPB_SIZE(2, 3), arena);
+ return (google_protobuf_EnumDescriptorProto**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(12, 40), len, UPB_SIZE(2, 3), arena);
}
UPB_INLINE struct google_protobuf_EnumDescriptorProto* google_protobuf_DescriptorProto_add_enum_type(google_protobuf_DescriptorProto* msg, upb_Arena* arena) {
struct google_protobuf_EnumDescriptorProto* sub = (struct google_protobuf_EnumDescriptorProto*)_upb_Message_New(&google_protobuf_EnumDescriptorProto_msg_init, arena);
- bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(20, 40), UPB_SIZE(2, 3), &sub, arena);
+ bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(12, 40), UPB_SIZE(2, 3), &sub, arena);
if (!ok) return NULL;
return sub;
}
UPB_INLINE google_protobuf_DescriptorProto_ExtensionRange** google_protobuf_DescriptorProto_mutable_extension_range(google_protobuf_DescriptorProto* msg, size_t* len) {
- return (google_protobuf_DescriptorProto_ExtensionRange**)_upb_array_mutable_accessor(msg, UPB_SIZE(24, 48), len);
+ return (google_protobuf_DescriptorProto_ExtensionRange**)_upb_array_mutable_accessor(msg, UPB_SIZE(16, 48), len);
}
UPB_INLINE google_protobuf_DescriptorProto_ExtensionRange** google_protobuf_DescriptorProto_resize_extension_range(google_protobuf_DescriptorProto* msg, size_t len, upb_Arena* arena) {
- return (google_protobuf_DescriptorProto_ExtensionRange**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(24, 48), len, UPB_SIZE(2, 3), arena);
+ return (google_protobuf_DescriptorProto_ExtensionRange**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(16, 48), len, UPB_SIZE(2, 3), arena);
}
UPB_INLINE struct google_protobuf_DescriptorProto_ExtensionRange* google_protobuf_DescriptorProto_add_extension_range(google_protobuf_DescriptorProto* msg, upb_Arena* arena) {
struct google_protobuf_DescriptorProto_ExtensionRange* sub = (struct google_protobuf_DescriptorProto_ExtensionRange*)_upb_Message_New(&google_protobuf_DescriptorProto_ExtensionRange_msg_init, arena);
- bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(24, 48), UPB_SIZE(2, 3), &sub, arena);
+ bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(16, 48), UPB_SIZE(2, 3), &sub, arena);
if (!ok) return NULL;
return sub;
}
UPB_INLINE google_protobuf_FieldDescriptorProto** google_protobuf_DescriptorProto_mutable_extension(google_protobuf_DescriptorProto* msg, size_t* len) {
- return (google_protobuf_FieldDescriptorProto**)_upb_array_mutable_accessor(msg, UPB_SIZE(28, 56), len);
+ return (google_protobuf_FieldDescriptorProto**)_upb_array_mutable_accessor(msg, UPB_SIZE(20, 56), len);
}
UPB_INLINE google_protobuf_FieldDescriptorProto** google_protobuf_DescriptorProto_resize_extension(google_protobuf_DescriptorProto* msg, size_t len, upb_Arena* arena) {
- return (google_protobuf_FieldDescriptorProto**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(28, 56), len, UPB_SIZE(2, 3), arena);
+ return (google_protobuf_FieldDescriptorProto**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(20, 56), len, UPB_SIZE(2, 3), arena);
}
UPB_INLINE struct google_protobuf_FieldDescriptorProto* google_protobuf_DescriptorProto_add_extension(google_protobuf_DescriptorProto* msg, upb_Arena* arena) {
struct google_protobuf_FieldDescriptorProto* sub = (struct google_protobuf_FieldDescriptorProto*)_upb_Message_New(&google_protobuf_FieldDescriptorProto_msg_init, arena);
- bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(28, 56), UPB_SIZE(2, 3), &sub, arena);
+ bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(20, 56), UPB_SIZE(2, 3), &sub, arena);
if (!ok) return NULL;
return sub;
}
UPB_INLINE void google_protobuf_DescriptorProto_set_options(google_protobuf_DescriptorProto *msg, google_protobuf_MessageOptions* value) {
_upb_sethas(msg, 2);
- *UPB_PTR_AT(msg, UPB_SIZE(32, 64), google_protobuf_MessageOptions*) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(24, 64), google_protobuf_MessageOptions*) = value;
}
UPB_INLINE struct google_protobuf_MessageOptions* google_protobuf_DescriptorProto_mutable_options(google_protobuf_DescriptorProto* msg, upb_Arena* arena) {
struct google_protobuf_MessageOptions* sub = (struct google_protobuf_MessageOptions*)google_protobuf_DescriptorProto_options(msg);
@@ -3091,37 +3089,37 @@
return sub;
}
UPB_INLINE google_protobuf_OneofDescriptorProto** google_protobuf_DescriptorProto_mutable_oneof_decl(google_protobuf_DescriptorProto* msg, size_t* len) {
- return (google_protobuf_OneofDescriptorProto**)_upb_array_mutable_accessor(msg, UPB_SIZE(36, 72), len);
+ return (google_protobuf_OneofDescriptorProto**)_upb_array_mutable_accessor(msg, UPB_SIZE(28, 72), len);
}
UPB_INLINE google_protobuf_OneofDescriptorProto** google_protobuf_DescriptorProto_resize_oneof_decl(google_protobuf_DescriptorProto* msg, size_t len, upb_Arena* arena) {
- return (google_protobuf_OneofDescriptorProto**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(36, 72), len, UPB_SIZE(2, 3), arena);
+ return (google_protobuf_OneofDescriptorProto**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(28, 72), len, UPB_SIZE(2, 3), arena);
}
UPB_INLINE struct google_protobuf_OneofDescriptorProto* google_protobuf_DescriptorProto_add_oneof_decl(google_protobuf_DescriptorProto* msg, upb_Arena* arena) {
struct google_protobuf_OneofDescriptorProto* sub = (struct google_protobuf_OneofDescriptorProto*)_upb_Message_New(&google_protobuf_OneofDescriptorProto_msg_init, arena);
- bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(36, 72), UPB_SIZE(2, 3), &sub, arena);
+ bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(28, 72), UPB_SIZE(2, 3), &sub, arena);
if (!ok) return NULL;
return sub;
}
UPB_INLINE google_protobuf_DescriptorProto_ReservedRange** google_protobuf_DescriptorProto_mutable_reserved_range(google_protobuf_DescriptorProto* msg, size_t* len) {
- return (google_protobuf_DescriptorProto_ReservedRange**)_upb_array_mutable_accessor(msg, UPB_SIZE(40, 80), len);
+ return (google_protobuf_DescriptorProto_ReservedRange**)_upb_array_mutable_accessor(msg, UPB_SIZE(32, 80), len);
}
UPB_INLINE google_protobuf_DescriptorProto_ReservedRange** google_protobuf_DescriptorProto_resize_reserved_range(google_protobuf_DescriptorProto* msg, size_t len, upb_Arena* arena) {
- return (google_protobuf_DescriptorProto_ReservedRange**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(40, 80), len, UPB_SIZE(2, 3), arena);
+ return (google_protobuf_DescriptorProto_ReservedRange**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(32, 80), len, UPB_SIZE(2, 3), arena);
}
UPB_INLINE struct google_protobuf_DescriptorProto_ReservedRange* google_protobuf_DescriptorProto_add_reserved_range(google_protobuf_DescriptorProto* msg, upb_Arena* arena) {
struct google_protobuf_DescriptorProto_ReservedRange* sub = (struct google_protobuf_DescriptorProto_ReservedRange*)_upb_Message_New(&google_protobuf_DescriptorProto_ReservedRange_msg_init, arena);
- bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(40, 80), UPB_SIZE(2, 3), &sub, arena);
+ bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(32, 80), UPB_SIZE(2, 3), &sub, arena);
if (!ok) return NULL;
return sub;
}
UPB_INLINE upb_StringView* google_protobuf_DescriptorProto_mutable_reserved_name(google_protobuf_DescriptorProto* msg, size_t* len) {
- return (upb_StringView*)_upb_array_mutable_accessor(msg, UPB_SIZE(44, 88), len);
+ return (upb_StringView*)_upb_array_mutable_accessor(msg, UPB_SIZE(36, 88), len);
}
UPB_INLINE upb_StringView* google_protobuf_DescriptorProto_resize_reserved_name(google_protobuf_DescriptorProto* msg, size_t len, upb_Arena* arena) {
- return (upb_StringView*)_upb_Array_Resize_accessor2(msg, UPB_SIZE(44, 88), len, UPB_SIZE(3, 4), arena);
+ return (upb_StringView*)_upb_Array_Resize_accessor2(msg, UPB_SIZE(36, 88), len, UPB_SIZE(3, 4), arena);
}
UPB_INLINE bool google_protobuf_DescriptorProto_add_reserved_name(google_protobuf_DescriptorProto* msg, upb_StringView val, upb_Arena* arena) {
- return _upb_Array_Append_accessor2(msg, UPB_SIZE(44, 88), UPB_SIZE(3, 4), &val, arena);
+ return _upb_Array_Append_accessor2(msg, UPB_SIZE(36, 88), UPB_SIZE(3, 4), &val, arena);
}
/* google.protobuf.DescriptorProto.ExtensionRange */
@@ -3374,21 +3372,21 @@
return _upb_hasbit(msg, 1);
}
UPB_INLINE void google_protobuf_FieldDescriptorProto_clear_name(const google_protobuf_FieldDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(24, 24), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(28, 24), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 1);
}
UPB_INLINE upb_StringView google_protobuf_FieldDescriptorProto_name(const google_protobuf_FieldDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(24, 24), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(28, 24), upb_StringView);
}
UPB_INLINE bool google_protobuf_FieldDescriptorProto_has_extendee(const google_protobuf_FieldDescriptorProto* msg) {
return _upb_hasbit(msg, 2);
}
UPB_INLINE void google_protobuf_FieldDescriptorProto_clear_extendee(const google_protobuf_FieldDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(32, 40), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(36, 40), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 2);
}
UPB_INLINE upb_StringView google_protobuf_FieldDescriptorProto_extendee(const google_protobuf_FieldDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(32, 40), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(36, 40), upb_StringView);
}
UPB_INLINE bool google_protobuf_FieldDescriptorProto_has_number(const google_protobuf_FieldDescriptorProto* msg) {
return _upb_hasbit(msg, 3);
@@ -3424,41 +3422,41 @@
return _upb_hasbit(msg, 6);
}
UPB_INLINE void google_protobuf_FieldDescriptorProto_clear_type_name(const google_protobuf_FieldDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(40, 56), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(44, 56), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 6);
}
UPB_INLINE upb_StringView google_protobuf_FieldDescriptorProto_type_name(const google_protobuf_FieldDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(40, 56), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(44, 56), upb_StringView);
}
UPB_INLINE bool google_protobuf_FieldDescriptorProto_has_default_value(const google_protobuf_FieldDescriptorProto* msg) {
return _upb_hasbit(msg, 7);
}
UPB_INLINE void google_protobuf_FieldDescriptorProto_clear_default_value(const google_protobuf_FieldDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(48, 72), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(52, 72), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 7);
}
UPB_INLINE upb_StringView google_protobuf_FieldDescriptorProto_default_value(const google_protobuf_FieldDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(48, 72), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(52, 72), upb_StringView);
}
UPB_INLINE bool google_protobuf_FieldDescriptorProto_has_options(const google_protobuf_FieldDescriptorProto* msg) {
return _upb_hasbit(msg, 8);
}
UPB_INLINE void google_protobuf_FieldDescriptorProto_clear_options(const google_protobuf_FieldDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(56, 88), const upb_Message*) = NULL;
+ *UPB_PTR_AT(msg, UPB_SIZE(16, 88), const upb_Message*) = NULL;
_upb_clearhas(msg, 8);
}
UPB_INLINE const google_protobuf_FieldOptions* google_protobuf_FieldDescriptorProto_options(const google_protobuf_FieldDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(56, 88), const google_protobuf_FieldOptions*);
+ return *UPB_PTR_AT(msg, UPB_SIZE(16, 88), const google_protobuf_FieldOptions*);
}
UPB_INLINE bool google_protobuf_FieldDescriptorProto_has_oneof_index(const google_protobuf_FieldDescriptorProto* msg) {
return _upb_hasbit(msg, 9);
}
UPB_INLINE void google_protobuf_FieldDescriptorProto_clear_oneof_index(const google_protobuf_FieldDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(16, 16), int32_t) = 0;
+ *UPB_PTR_AT(msg, UPB_SIZE(20, 16), int32_t) = 0;
_upb_clearhas(msg, 9);
}
UPB_INLINE int32_t google_protobuf_FieldDescriptorProto_oneof_index(const google_protobuf_FieldDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(16, 16), int32_t);
+ return *UPB_PTR_AT(msg, UPB_SIZE(20, 16), int32_t);
}
UPB_INLINE bool google_protobuf_FieldDescriptorProto_has_json_name(const google_protobuf_FieldDescriptorProto* msg) {
return _upb_hasbit(msg, 10);
@@ -3474,20 +3472,20 @@
return _upb_hasbit(msg, 11);
}
UPB_INLINE void google_protobuf_FieldDescriptorProto_clear_proto3_optional(const google_protobuf_FieldDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(20, 20), bool) = 0;
+ *UPB_PTR_AT(msg, UPB_SIZE(24, 20), bool) = 0;
_upb_clearhas(msg, 11);
}
UPB_INLINE bool google_protobuf_FieldDescriptorProto_proto3_optional(const google_protobuf_FieldDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(20, 20), bool);
+ return *UPB_PTR_AT(msg, UPB_SIZE(24, 20), bool);
}
UPB_INLINE void google_protobuf_FieldDescriptorProto_set_name(google_protobuf_FieldDescriptorProto *msg, upb_StringView value) {
_upb_sethas(msg, 1);
- *UPB_PTR_AT(msg, UPB_SIZE(24, 24), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(28, 24), upb_StringView) = value;
}
UPB_INLINE void google_protobuf_FieldDescriptorProto_set_extendee(google_protobuf_FieldDescriptorProto *msg, upb_StringView value) {
_upb_sethas(msg, 2);
- *UPB_PTR_AT(msg, UPB_SIZE(32, 40), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(36, 40), upb_StringView) = value;
}
UPB_INLINE void google_protobuf_FieldDescriptorProto_set_number(google_protobuf_FieldDescriptorProto *msg, int32_t value) {
_upb_sethas(msg, 3);
@@ -3503,15 +3501,15 @@
}
UPB_INLINE void google_protobuf_FieldDescriptorProto_set_type_name(google_protobuf_FieldDescriptorProto *msg, upb_StringView value) {
_upb_sethas(msg, 6);
- *UPB_PTR_AT(msg, UPB_SIZE(40, 56), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(44, 56), upb_StringView) = value;
}
UPB_INLINE void google_protobuf_FieldDescriptorProto_set_default_value(google_protobuf_FieldDescriptorProto *msg, upb_StringView value) {
_upb_sethas(msg, 7);
- *UPB_PTR_AT(msg, UPB_SIZE(48, 72), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(52, 72), upb_StringView) = value;
}
UPB_INLINE void google_protobuf_FieldDescriptorProto_set_options(google_protobuf_FieldDescriptorProto *msg, google_protobuf_FieldOptions* value) {
_upb_sethas(msg, 8);
- *UPB_PTR_AT(msg, UPB_SIZE(56, 88), google_protobuf_FieldOptions*) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(16, 88), google_protobuf_FieldOptions*) = value;
}
UPB_INLINE struct google_protobuf_FieldOptions* google_protobuf_FieldDescriptorProto_mutable_options(google_protobuf_FieldDescriptorProto* msg, upb_Arena* arena) {
struct google_protobuf_FieldOptions* sub = (struct google_protobuf_FieldOptions*)google_protobuf_FieldDescriptorProto_options(msg);
@@ -3524,7 +3522,7 @@
}
UPB_INLINE void google_protobuf_FieldDescriptorProto_set_oneof_index(google_protobuf_FieldDescriptorProto *msg, int32_t value) {
_upb_sethas(msg, 9);
- *UPB_PTR_AT(msg, UPB_SIZE(16, 16), int32_t) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(20, 16), int32_t) = value;
}
UPB_INLINE void google_protobuf_FieldDescriptorProto_set_json_name(google_protobuf_FieldDescriptorProto *msg, upb_StringView value) {
_upb_sethas(msg, 10);
@@ -3532,7 +3530,7 @@
}
UPB_INLINE void google_protobuf_FieldDescriptorProto_set_proto3_optional(google_protobuf_FieldDescriptorProto *msg, bool value) {
_upb_sethas(msg, 11);
- *UPB_PTR_AT(msg, UPB_SIZE(20, 20), bool) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(24, 20), bool) = value;
}
/* google.protobuf.OneofDescriptorProto */
@@ -3574,30 +3572,30 @@
return _upb_hasbit(msg, 1);
}
UPB_INLINE void google_protobuf_OneofDescriptorProto_clear_name(const google_protobuf_OneofDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(8, 8), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 1);
}
UPB_INLINE upb_StringView google_protobuf_OneofDescriptorProto_name(const google_protobuf_OneofDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(8, 8), upb_StringView);
}
UPB_INLINE bool google_protobuf_OneofDescriptorProto_has_options(const google_protobuf_OneofDescriptorProto* msg) {
return _upb_hasbit(msg, 2);
}
UPB_INLINE void google_protobuf_OneofDescriptorProto_clear_options(const google_protobuf_OneofDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(12, 24), const upb_Message*) = NULL;
+ *UPB_PTR_AT(msg, UPB_SIZE(4, 24), const upb_Message*) = NULL;
_upb_clearhas(msg, 2);
}
UPB_INLINE const google_protobuf_OneofOptions* google_protobuf_OneofDescriptorProto_options(const google_protobuf_OneofDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(12, 24), const google_protobuf_OneofOptions*);
+ return *UPB_PTR_AT(msg, UPB_SIZE(4, 24), const google_protobuf_OneofOptions*);
}
UPB_INLINE void google_protobuf_OneofDescriptorProto_set_name(google_protobuf_OneofDescriptorProto *msg, upb_StringView value) {
_upb_sethas(msg, 1);
- *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(8, 8), upb_StringView) = value;
}
UPB_INLINE void google_protobuf_OneofDescriptorProto_set_options(google_protobuf_OneofDescriptorProto *msg, google_protobuf_OneofOptions* value) {
_upb_sethas(msg, 2);
- *UPB_PTR_AT(msg, UPB_SIZE(12, 24), google_protobuf_OneofOptions*) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(4, 24), google_protobuf_OneofOptions*) = value;
}
UPB_INLINE struct google_protobuf_OneofOptions* google_protobuf_OneofDescriptorProto_mutable_options(google_protobuf_OneofDescriptorProto* msg, upb_Arena* arena) {
struct google_protobuf_OneofOptions* sub = (struct google_protobuf_OneofOptions*)google_protobuf_OneofDescriptorProto_options(msg);
@@ -3648,66 +3646,66 @@
return _upb_hasbit(msg, 1);
}
UPB_INLINE void google_protobuf_EnumDescriptorProto_clear_name(const google_protobuf_EnumDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(20, 8), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 1);
}
UPB_INLINE upb_StringView google_protobuf_EnumDescriptorProto_name(const google_protobuf_EnumDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(20, 8), upb_StringView);
}
UPB_INLINE bool google_protobuf_EnumDescriptorProto_has_value(const google_protobuf_EnumDescriptorProto* msg) {
- return _upb_has_submsg_nohasbit(msg, UPB_SIZE(12, 24));
+ return _upb_has_submsg_nohasbit(msg, UPB_SIZE(4, 24));
}
UPB_INLINE void google_protobuf_EnumDescriptorProto_clear_value(const google_protobuf_EnumDescriptorProto* msg) {
- _upb_array_detach(msg, UPB_SIZE(12, 24));
+ _upb_array_detach(msg, UPB_SIZE(4, 24));
}
UPB_INLINE const google_protobuf_EnumValueDescriptorProto* const* google_protobuf_EnumDescriptorProto_value(const google_protobuf_EnumDescriptorProto* msg, size_t* len) {
- return (const google_protobuf_EnumValueDescriptorProto* const*)_upb_array_accessor(msg, UPB_SIZE(12, 24), len);
+ return (const google_protobuf_EnumValueDescriptorProto* const*)_upb_array_accessor(msg, UPB_SIZE(4, 24), len);
}
UPB_INLINE bool google_protobuf_EnumDescriptorProto_has_options(const google_protobuf_EnumDescriptorProto* msg) {
return _upb_hasbit(msg, 2);
}
UPB_INLINE void google_protobuf_EnumDescriptorProto_clear_options(const google_protobuf_EnumDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(16, 32), const upb_Message*) = NULL;
+ *UPB_PTR_AT(msg, UPB_SIZE(8, 32), const upb_Message*) = NULL;
_upb_clearhas(msg, 2);
}
UPB_INLINE const google_protobuf_EnumOptions* google_protobuf_EnumDescriptorProto_options(const google_protobuf_EnumDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(16, 32), const google_protobuf_EnumOptions*);
+ return *UPB_PTR_AT(msg, UPB_SIZE(8, 32), const google_protobuf_EnumOptions*);
}
UPB_INLINE bool google_protobuf_EnumDescriptorProto_has_reserved_range(const google_protobuf_EnumDescriptorProto* msg) {
- return _upb_has_submsg_nohasbit(msg, UPB_SIZE(20, 40));
+ return _upb_has_submsg_nohasbit(msg, UPB_SIZE(12, 40));
}
UPB_INLINE void google_protobuf_EnumDescriptorProto_clear_reserved_range(const google_protobuf_EnumDescriptorProto* msg) {
- _upb_array_detach(msg, UPB_SIZE(20, 40));
+ _upb_array_detach(msg, UPB_SIZE(12, 40));
}
UPB_INLINE const google_protobuf_EnumDescriptorProto_EnumReservedRange* const* google_protobuf_EnumDescriptorProto_reserved_range(const google_protobuf_EnumDescriptorProto* msg, size_t* len) {
- return (const google_protobuf_EnumDescriptorProto_EnumReservedRange* const*)_upb_array_accessor(msg, UPB_SIZE(20, 40), len);
+ return (const google_protobuf_EnumDescriptorProto_EnumReservedRange* const*)_upb_array_accessor(msg, UPB_SIZE(12, 40), len);
}
UPB_INLINE void google_protobuf_EnumDescriptorProto_clear_reserved_name(const google_protobuf_EnumDescriptorProto* msg) {
- _upb_array_detach(msg, UPB_SIZE(24, 48));
+ _upb_array_detach(msg, UPB_SIZE(16, 48));
}
UPB_INLINE upb_StringView const* google_protobuf_EnumDescriptorProto_reserved_name(const google_protobuf_EnumDescriptorProto* msg, size_t* len) {
- return (upb_StringView const*)_upb_array_accessor(msg, UPB_SIZE(24, 48), len);
+ return (upb_StringView const*)_upb_array_accessor(msg, UPB_SIZE(16, 48), len);
}
UPB_INLINE void google_protobuf_EnumDescriptorProto_set_name(google_protobuf_EnumDescriptorProto *msg, upb_StringView value) {
_upb_sethas(msg, 1);
- *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(20, 8), upb_StringView) = value;
}
UPB_INLINE google_protobuf_EnumValueDescriptorProto** google_protobuf_EnumDescriptorProto_mutable_value(google_protobuf_EnumDescriptorProto* msg, size_t* len) {
- return (google_protobuf_EnumValueDescriptorProto**)_upb_array_mutable_accessor(msg, UPB_SIZE(12, 24), len);
+ return (google_protobuf_EnumValueDescriptorProto**)_upb_array_mutable_accessor(msg, UPB_SIZE(4, 24), len);
}
UPB_INLINE google_protobuf_EnumValueDescriptorProto** google_protobuf_EnumDescriptorProto_resize_value(google_protobuf_EnumDescriptorProto* msg, size_t len, upb_Arena* arena) {
- return (google_protobuf_EnumValueDescriptorProto**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(12, 24), len, UPB_SIZE(2, 3), arena);
+ return (google_protobuf_EnumValueDescriptorProto**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(4, 24), len, UPB_SIZE(2, 3), arena);
}
UPB_INLINE struct google_protobuf_EnumValueDescriptorProto* google_protobuf_EnumDescriptorProto_add_value(google_protobuf_EnumDescriptorProto* msg, upb_Arena* arena) {
struct google_protobuf_EnumValueDescriptorProto* sub = (struct google_protobuf_EnumValueDescriptorProto*)_upb_Message_New(&google_protobuf_EnumValueDescriptorProto_msg_init, arena);
- bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(12, 24), UPB_SIZE(2, 3), &sub, arena);
+ bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(4, 24), UPB_SIZE(2, 3), &sub, arena);
if (!ok) return NULL;
return sub;
}
UPB_INLINE void google_protobuf_EnumDescriptorProto_set_options(google_protobuf_EnumDescriptorProto *msg, google_protobuf_EnumOptions* value) {
_upb_sethas(msg, 2);
- *UPB_PTR_AT(msg, UPB_SIZE(16, 32), google_protobuf_EnumOptions*) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(8, 32), google_protobuf_EnumOptions*) = value;
}
UPB_INLINE struct google_protobuf_EnumOptions* google_protobuf_EnumDescriptorProto_mutable_options(google_protobuf_EnumDescriptorProto* msg, upb_Arena* arena) {
struct google_protobuf_EnumOptions* sub = (struct google_protobuf_EnumOptions*)google_protobuf_EnumDescriptorProto_options(msg);
@@ -3719,25 +3717,25 @@
return sub;
}
UPB_INLINE google_protobuf_EnumDescriptorProto_EnumReservedRange** google_protobuf_EnumDescriptorProto_mutable_reserved_range(google_protobuf_EnumDescriptorProto* msg, size_t* len) {
- return (google_protobuf_EnumDescriptorProto_EnumReservedRange**)_upb_array_mutable_accessor(msg, UPB_SIZE(20, 40), len);
+ return (google_protobuf_EnumDescriptorProto_EnumReservedRange**)_upb_array_mutable_accessor(msg, UPB_SIZE(12, 40), len);
}
UPB_INLINE google_protobuf_EnumDescriptorProto_EnumReservedRange** google_protobuf_EnumDescriptorProto_resize_reserved_range(google_protobuf_EnumDescriptorProto* msg, size_t len, upb_Arena* arena) {
- return (google_protobuf_EnumDescriptorProto_EnumReservedRange**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(20, 40), len, UPB_SIZE(2, 3), arena);
+ return (google_protobuf_EnumDescriptorProto_EnumReservedRange**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(12, 40), len, UPB_SIZE(2, 3), arena);
}
UPB_INLINE struct google_protobuf_EnumDescriptorProto_EnumReservedRange* google_protobuf_EnumDescriptorProto_add_reserved_range(google_protobuf_EnumDescriptorProto* msg, upb_Arena* arena) {
struct google_protobuf_EnumDescriptorProto_EnumReservedRange* sub = (struct google_protobuf_EnumDescriptorProto_EnumReservedRange*)_upb_Message_New(&google_protobuf_EnumDescriptorProto_EnumReservedRange_msg_init, arena);
- bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(20, 40), UPB_SIZE(2, 3), &sub, arena);
+ bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(12, 40), UPB_SIZE(2, 3), &sub, arena);
if (!ok) return NULL;
return sub;
}
UPB_INLINE upb_StringView* google_protobuf_EnumDescriptorProto_mutable_reserved_name(google_protobuf_EnumDescriptorProto* msg, size_t* len) {
- return (upb_StringView*)_upb_array_mutable_accessor(msg, UPB_SIZE(24, 48), len);
+ return (upb_StringView*)_upb_array_mutable_accessor(msg, UPB_SIZE(16, 48), len);
}
UPB_INLINE upb_StringView* google_protobuf_EnumDescriptorProto_resize_reserved_name(google_protobuf_EnumDescriptorProto* msg, size_t len, upb_Arena* arena) {
- return (upb_StringView*)_upb_Array_Resize_accessor2(msg, UPB_SIZE(24, 48), len, UPB_SIZE(3, 4), arena);
+ return (upb_StringView*)_upb_Array_Resize_accessor2(msg, UPB_SIZE(16, 48), len, UPB_SIZE(3, 4), arena);
}
UPB_INLINE bool google_protobuf_EnumDescriptorProto_add_reserved_name(google_protobuf_EnumDescriptorProto* msg, upb_StringView val, upb_Arena* arena) {
- return _upb_Array_Append_accessor2(msg, UPB_SIZE(24, 48), UPB_SIZE(3, 4), &val, arena);
+ return _upb_Array_Append_accessor2(msg, UPB_SIZE(16, 48), UPB_SIZE(3, 4), &val, arena);
}
/* google.protobuf.EnumDescriptorProto.EnumReservedRange */
@@ -3844,11 +3842,11 @@
return _upb_hasbit(msg, 1);
}
UPB_INLINE void google_protobuf_EnumValueDescriptorProto_clear_name(const google_protobuf_EnumValueDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(8, 8), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(12, 8), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 1);
}
UPB_INLINE upb_StringView google_protobuf_EnumValueDescriptorProto_name(const google_protobuf_EnumValueDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(8, 8), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(12, 8), upb_StringView);
}
UPB_INLINE bool google_protobuf_EnumValueDescriptorProto_has_number(const google_protobuf_EnumValueDescriptorProto* msg) {
return _upb_hasbit(msg, 2);
@@ -3864,16 +3862,16 @@
return _upb_hasbit(msg, 3);
}
UPB_INLINE void google_protobuf_EnumValueDescriptorProto_clear_options(const google_protobuf_EnumValueDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(16, 24), const upb_Message*) = NULL;
+ *UPB_PTR_AT(msg, UPB_SIZE(8, 24), const upb_Message*) = NULL;
_upb_clearhas(msg, 3);
}
UPB_INLINE const google_protobuf_EnumValueOptions* google_protobuf_EnumValueDescriptorProto_options(const google_protobuf_EnumValueDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(16, 24), const google_protobuf_EnumValueOptions*);
+ return *UPB_PTR_AT(msg, UPB_SIZE(8, 24), const google_protobuf_EnumValueOptions*);
}
UPB_INLINE void google_protobuf_EnumValueDescriptorProto_set_name(google_protobuf_EnumValueDescriptorProto *msg, upb_StringView value) {
_upb_sethas(msg, 1);
- *UPB_PTR_AT(msg, UPB_SIZE(8, 8), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(12, 8), upb_StringView) = value;
}
UPB_INLINE void google_protobuf_EnumValueDescriptorProto_set_number(google_protobuf_EnumValueDescriptorProto *msg, int32_t value) {
_upb_sethas(msg, 2);
@@ -3881,7 +3879,7 @@
}
UPB_INLINE void google_protobuf_EnumValueDescriptorProto_set_options(google_protobuf_EnumValueDescriptorProto *msg, google_protobuf_EnumValueOptions* value) {
_upb_sethas(msg, 3);
- *UPB_PTR_AT(msg, UPB_SIZE(16, 24), google_protobuf_EnumValueOptions*) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(8, 24), google_protobuf_EnumValueOptions*) = value;
}
UPB_INLINE struct google_protobuf_EnumValueOptions* google_protobuf_EnumValueDescriptorProto_mutable_options(google_protobuf_EnumValueDescriptorProto* msg, upb_Arena* arena) {
struct google_protobuf_EnumValueOptions* sub = (struct google_protobuf_EnumValueOptions*)google_protobuf_EnumValueDescriptorProto_options(msg);
@@ -3932,51 +3930,51 @@
return _upb_hasbit(msg, 1);
}
UPB_INLINE void google_protobuf_ServiceDescriptorProto_clear_name(const google_protobuf_ServiceDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(12, 8), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 1);
}
UPB_INLINE upb_StringView google_protobuf_ServiceDescriptorProto_name(const google_protobuf_ServiceDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(12, 8), upb_StringView);
}
UPB_INLINE bool google_protobuf_ServiceDescriptorProto_has_method(const google_protobuf_ServiceDescriptorProto* msg) {
- return _upb_has_submsg_nohasbit(msg, UPB_SIZE(12, 24));
+ return _upb_has_submsg_nohasbit(msg, UPB_SIZE(4, 24));
}
UPB_INLINE void google_protobuf_ServiceDescriptorProto_clear_method(const google_protobuf_ServiceDescriptorProto* msg) {
- _upb_array_detach(msg, UPB_SIZE(12, 24));
+ _upb_array_detach(msg, UPB_SIZE(4, 24));
}
UPB_INLINE const google_protobuf_MethodDescriptorProto* const* google_protobuf_ServiceDescriptorProto_method(const google_protobuf_ServiceDescriptorProto* msg, size_t* len) {
- return (const google_protobuf_MethodDescriptorProto* const*)_upb_array_accessor(msg, UPB_SIZE(12, 24), len);
+ return (const google_protobuf_MethodDescriptorProto* const*)_upb_array_accessor(msg, UPB_SIZE(4, 24), len);
}
UPB_INLINE bool google_protobuf_ServiceDescriptorProto_has_options(const google_protobuf_ServiceDescriptorProto* msg) {
return _upb_hasbit(msg, 2);
}
UPB_INLINE void google_protobuf_ServiceDescriptorProto_clear_options(const google_protobuf_ServiceDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(16, 32), const upb_Message*) = NULL;
+ *UPB_PTR_AT(msg, UPB_SIZE(8, 32), const upb_Message*) = NULL;
_upb_clearhas(msg, 2);
}
UPB_INLINE const google_protobuf_ServiceOptions* google_protobuf_ServiceDescriptorProto_options(const google_protobuf_ServiceDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(16, 32), const google_protobuf_ServiceOptions*);
+ return *UPB_PTR_AT(msg, UPB_SIZE(8, 32), const google_protobuf_ServiceOptions*);
}
UPB_INLINE void google_protobuf_ServiceDescriptorProto_set_name(google_protobuf_ServiceDescriptorProto *msg, upb_StringView value) {
_upb_sethas(msg, 1);
- *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(12, 8), upb_StringView) = value;
}
UPB_INLINE google_protobuf_MethodDescriptorProto** google_protobuf_ServiceDescriptorProto_mutable_method(google_protobuf_ServiceDescriptorProto* msg, size_t* len) {
- return (google_protobuf_MethodDescriptorProto**)_upb_array_mutable_accessor(msg, UPB_SIZE(12, 24), len);
+ return (google_protobuf_MethodDescriptorProto**)_upb_array_mutable_accessor(msg, UPB_SIZE(4, 24), len);
}
UPB_INLINE google_protobuf_MethodDescriptorProto** google_protobuf_ServiceDescriptorProto_resize_method(google_protobuf_ServiceDescriptorProto* msg, size_t len, upb_Arena* arena) {
- return (google_protobuf_MethodDescriptorProto**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(12, 24), len, UPB_SIZE(2, 3), arena);
+ return (google_protobuf_MethodDescriptorProto**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(4, 24), len, UPB_SIZE(2, 3), arena);
}
UPB_INLINE struct google_protobuf_MethodDescriptorProto* google_protobuf_ServiceDescriptorProto_add_method(google_protobuf_ServiceDescriptorProto* msg, upb_Arena* arena) {
struct google_protobuf_MethodDescriptorProto* sub = (struct google_protobuf_MethodDescriptorProto*)_upb_Message_New(&google_protobuf_MethodDescriptorProto_msg_init, arena);
- bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(12, 24), UPB_SIZE(2, 3), &sub, arena);
+ bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(4, 24), UPB_SIZE(2, 3), &sub, arena);
if (!ok) return NULL;
return sub;
}
UPB_INLINE void google_protobuf_ServiceDescriptorProto_set_options(google_protobuf_ServiceDescriptorProto *msg, google_protobuf_ServiceOptions* value) {
_upb_sethas(msg, 2);
- *UPB_PTR_AT(msg, UPB_SIZE(16, 32), google_protobuf_ServiceOptions*) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(8, 32), google_protobuf_ServiceOptions*) = value;
}
UPB_INLINE struct google_protobuf_ServiceOptions* google_protobuf_ServiceDescriptorProto_mutable_options(google_protobuf_ServiceDescriptorProto* msg, upb_Arena* arena) {
struct google_protobuf_ServiceOptions* sub = (struct google_protobuf_ServiceOptions*)google_protobuf_ServiceDescriptorProto_options(msg);
@@ -4027,78 +4025,78 @@
return _upb_hasbit(msg, 1);
}
UPB_INLINE void google_protobuf_MethodDescriptorProto_clear_name(const google_protobuf_MethodDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(12, 8), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 1);
}
UPB_INLINE upb_StringView google_protobuf_MethodDescriptorProto_name(const google_protobuf_MethodDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(12, 8), upb_StringView);
}
UPB_INLINE bool google_protobuf_MethodDescriptorProto_has_input_type(const google_protobuf_MethodDescriptorProto* msg) {
return _upb_hasbit(msg, 2);
}
UPB_INLINE void google_protobuf_MethodDescriptorProto_clear_input_type(const google_protobuf_MethodDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(12, 24), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(20, 24), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 2);
}
UPB_INLINE upb_StringView google_protobuf_MethodDescriptorProto_input_type(const google_protobuf_MethodDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(12, 24), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(20, 24), upb_StringView);
}
UPB_INLINE bool google_protobuf_MethodDescriptorProto_has_output_type(const google_protobuf_MethodDescriptorProto* msg) {
return _upb_hasbit(msg, 3);
}
UPB_INLINE void google_protobuf_MethodDescriptorProto_clear_output_type(const google_protobuf_MethodDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(20, 40), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(28, 40), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 3);
}
UPB_INLINE upb_StringView google_protobuf_MethodDescriptorProto_output_type(const google_protobuf_MethodDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(20, 40), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(28, 40), upb_StringView);
}
UPB_INLINE bool google_protobuf_MethodDescriptorProto_has_options(const google_protobuf_MethodDescriptorProto* msg) {
return _upb_hasbit(msg, 4);
}
UPB_INLINE void google_protobuf_MethodDescriptorProto_clear_options(const google_protobuf_MethodDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(28, 56), const upb_Message*) = NULL;
+ *UPB_PTR_AT(msg, UPB_SIZE(4, 56), const upb_Message*) = NULL;
_upb_clearhas(msg, 4);
}
UPB_INLINE const google_protobuf_MethodOptions* google_protobuf_MethodDescriptorProto_options(const google_protobuf_MethodDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(28, 56), const google_protobuf_MethodOptions*);
+ return *UPB_PTR_AT(msg, UPB_SIZE(4, 56), const google_protobuf_MethodOptions*);
}
UPB_INLINE bool google_protobuf_MethodDescriptorProto_has_client_streaming(const google_protobuf_MethodDescriptorProto* msg) {
return _upb_hasbit(msg, 5);
}
UPB_INLINE void google_protobuf_MethodDescriptorProto_clear_client_streaming(const google_protobuf_MethodDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(1, 1), bool) = 0;
+ *UPB_PTR_AT(msg, UPB_SIZE(8, 1), bool) = 0;
_upb_clearhas(msg, 5);
}
UPB_INLINE bool google_protobuf_MethodDescriptorProto_client_streaming(const google_protobuf_MethodDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(1, 1), bool);
+ return *UPB_PTR_AT(msg, UPB_SIZE(8, 1), bool);
}
UPB_INLINE bool google_protobuf_MethodDescriptorProto_has_server_streaming(const google_protobuf_MethodDescriptorProto* msg) {
return _upb_hasbit(msg, 6);
}
UPB_INLINE void google_protobuf_MethodDescriptorProto_clear_server_streaming(const google_protobuf_MethodDescriptorProto* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(2, 2), bool) = 0;
+ *UPB_PTR_AT(msg, UPB_SIZE(9, 2), bool) = 0;
_upb_clearhas(msg, 6);
}
UPB_INLINE bool google_protobuf_MethodDescriptorProto_server_streaming(const google_protobuf_MethodDescriptorProto* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(2, 2), bool);
+ return *UPB_PTR_AT(msg, UPB_SIZE(9, 2), bool);
}
UPB_INLINE void google_protobuf_MethodDescriptorProto_set_name(google_protobuf_MethodDescriptorProto *msg, upb_StringView value) {
_upb_sethas(msg, 1);
- *UPB_PTR_AT(msg, UPB_SIZE(4, 8), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(12, 8), upb_StringView) = value;
}
UPB_INLINE void google_protobuf_MethodDescriptorProto_set_input_type(google_protobuf_MethodDescriptorProto *msg, upb_StringView value) {
_upb_sethas(msg, 2);
- *UPB_PTR_AT(msg, UPB_SIZE(12, 24), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(20, 24), upb_StringView) = value;
}
UPB_INLINE void google_protobuf_MethodDescriptorProto_set_output_type(google_protobuf_MethodDescriptorProto *msg, upb_StringView value) {
_upb_sethas(msg, 3);
- *UPB_PTR_AT(msg, UPB_SIZE(20, 40), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(28, 40), upb_StringView) = value;
}
UPB_INLINE void google_protobuf_MethodDescriptorProto_set_options(google_protobuf_MethodDescriptorProto *msg, google_protobuf_MethodOptions* value) {
_upb_sethas(msg, 4);
- *UPB_PTR_AT(msg, UPB_SIZE(28, 56), google_protobuf_MethodOptions*) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(4, 56), google_protobuf_MethodOptions*) = value;
}
UPB_INLINE struct google_protobuf_MethodOptions* google_protobuf_MethodDescriptorProto_mutable_options(google_protobuf_MethodDescriptorProto* msg, upb_Arena* arena) {
struct google_protobuf_MethodOptions* sub = (struct google_protobuf_MethodOptions*)google_protobuf_MethodDescriptorProto_options(msg);
@@ -4111,11 +4109,11 @@
}
UPB_INLINE void google_protobuf_MethodDescriptorProto_set_client_streaming(google_protobuf_MethodDescriptorProto *msg, bool value) {
_upb_sethas(msg, 5);
- *UPB_PTR_AT(msg, UPB_SIZE(1, 1), bool) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(8, 1), bool) = value;
}
UPB_INLINE void google_protobuf_MethodDescriptorProto_set_server_streaming(google_protobuf_MethodDescriptorProto *msg, bool value) {
_upb_sethas(msg, 6);
- *UPB_PTR_AT(msg, UPB_SIZE(2, 2), bool) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(9, 2), bool) = value;
}
/* google.protobuf.FileOptions */
@@ -4157,21 +4155,21 @@
return _upb_hasbit(msg, 1);
}
UPB_INLINE void google_protobuf_FileOptions_clear_java_package(const google_protobuf_FileOptions* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(20, 24), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(24, 24), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 1);
}
UPB_INLINE upb_StringView google_protobuf_FileOptions_java_package(const google_protobuf_FileOptions* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(20, 24), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(24, 24), upb_StringView);
}
UPB_INLINE bool google_protobuf_FileOptions_has_java_outer_classname(const google_protobuf_FileOptions* msg) {
return _upb_hasbit(msg, 2);
}
UPB_INLINE void google_protobuf_FileOptions_clear_java_outer_classname(const google_protobuf_FileOptions* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(28, 40), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(32, 40), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 2);
}
UPB_INLINE upb_StringView google_protobuf_FileOptions_java_outer_classname(const google_protobuf_FileOptions* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(28, 40), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(32, 40), upb_StringView);
}
UPB_INLINE bool google_protobuf_FileOptions_has_optimize_for(const google_protobuf_FileOptions* msg) {
return _upb_hasbit(msg, 3);
@@ -4197,11 +4195,11 @@
return _upb_hasbit(msg, 5);
}
UPB_INLINE void google_protobuf_FileOptions_clear_go_package(const google_protobuf_FileOptions* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(36, 56), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(40, 56), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 5);
}
UPB_INLINE upb_StringView google_protobuf_FileOptions_go_package(const google_protobuf_FileOptions* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(36, 56), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(40, 56), upb_StringView);
}
UPB_INLINE bool google_protobuf_FileOptions_has_cc_generic_services(const google_protobuf_FileOptions* msg) {
return _upb_hasbit(msg, 6);
@@ -4277,51 +4275,51 @@
return _upb_hasbit(msg, 13);
}
UPB_INLINE void google_protobuf_FileOptions_clear_objc_class_prefix(const google_protobuf_FileOptions* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(44, 72), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(48, 72), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 13);
}
UPB_INLINE upb_StringView google_protobuf_FileOptions_objc_class_prefix(const google_protobuf_FileOptions* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(44, 72), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(48, 72), upb_StringView);
}
UPB_INLINE bool google_protobuf_FileOptions_has_csharp_namespace(const google_protobuf_FileOptions* msg) {
return _upb_hasbit(msg, 14);
}
UPB_INLINE void google_protobuf_FileOptions_clear_csharp_namespace(const google_protobuf_FileOptions* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(52, 88), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(56, 88), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 14);
}
UPB_INLINE upb_StringView google_protobuf_FileOptions_csharp_namespace(const google_protobuf_FileOptions* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(52, 88), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(56, 88), upb_StringView);
}
UPB_INLINE bool google_protobuf_FileOptions_has_swift_prefix(const google_protobuf_FileOptions* msg) {
return _upb_hasbit(msg, 15);
}
UPB_INLINE void google_protobuf_FileOptions_clear_swift_prefix(const google_protobuf_FileOptions* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(60, 104), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(64, 104), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 15);
}
UPB_INLINE upb_StringView google_protobuf_FileOptions_swift_prefix(const google_protobuf_FileOptions* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(60, 104), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(64, 104), upb_StringView);
}
UPB_INLINE bool google_protobuf_FileOptions_has_php_class_prefix(const google_protobuf_FileOptions* msg) {
return _upb_hasbit(msg, 16);
}
UPB_INLINE void google_protobuf_FileOptions_clear_php_class_prefix(const google_protobuf_FileOptions* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(68, 120), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(72, 120), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 16);
}
UPB_INLINE upb_StringView google_protobuf_FileOptions_php_class_prefix(const google_protobuf_FileOptions* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(68, 120), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(72, 120), upb_StringView);
}
UPB_INLINE bool google_protobuf_FileOptions_has_php_namespace(const google_protobuf_FileOptions* msg) {
return _upb_hasbit(msg, 17);
}
UPB_INLINE void google_protobuf_FileOptions_clear_php_namespace(const google_protobuf_FileOptions* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(76, 136), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(80, 136), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 17);
}
UPB_INLINE upb_StringView google_protobuf_FileOptions_php_namespace(const google_protobuf_FileOptions* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(76, 136), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(80, 136), upb_StringView);
}
UPB_INLINE bool google_protobuf_FileOptions_has_php_generic_services(const google_protobuf_FileOptions* msg) {
return _upb_hasbit(msg, 18);
@@ -4337,39 +4335,39 @@
return _upb_hasbit(msg, 19);
}
UPB_INLINE void google_protobuf_FileOptions_clear_php_metadata_namespace(const google_protobuf_FileOptions* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(84, 152), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(88, 152), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 19);
}
UPB_INLINE upb_StringView google_protobuf_FileOptions_php_metadata_namespace(const google_protobuf_FileOptions* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(84, 152), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(88, 152), upb_StringView);
}
UPB_INLINE bool google_protobuf_FileOptions_has_ruby_package(const google_protobuf_FileOptions* msg) {
return _upb_hasbit(msg, 20);
}
UPB_INLINE void google_protobuf_FileOptions_clear_ruby_package(const google_protobuf_FileOptions* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(92, 168), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(96, 168), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 20);
}
UPB_INLINE upb_StringView google_protobuf_FileOptions_ruby_package(const google_protobuf_FileOptions* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(92, 168), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(96, 168), upb_StringView);
}
UPB_INLINE bool google_protobuf_FileOptions_has_uninterpreted_option(const google_protobuf_FileOptions* msg) {
- return _upb_has_submsg_nohasbit(msg, UPB_SIZE(100, 184));
+ return _upb_has_submsg_nohasbit(msg, UPB_SIZE(20, 184));
}
UPB_INLINE void google_protobuf_FileOptions_clear_uninterpreted_option(const google_protobuf_FileOptions* msg) {
- _upb_array_detach(msg, UPB_SIZE(100, 184));
+ _upb_array_detach(msg, UPB_SIZE(20, 184));
}
UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_FileOptions_uninterpreted_option(const google_protobuf_FileOptions* msg, size_t* len) {
- return (const google_protobuf_UninterpretedOption* const*)_upb_array_accessor(msg, UPB_SIZE(100, 184), len);
+ return (const google_protobuf_UninterpretedOption* const*)_upb_array_accessor(msg, UPB_SIZE(20, 184), len);
}
UPB_INLINE void google_protobuf_FileOptions_set_java_package(google_protobuf_FileOptions *msg, upb_StringView value) {
_upb_sethas(msg, 1);
- *UPB_PTR_AT(msg, UPB_SIZE(20, 24), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(24, 24), upb_StringView) = value;
}
UPB_INLINE void google_protobuf_FileOptions_set_java_outer_classname(google_protobuf_FileOptions *msg, upb_StringView value) {
_upb_sethas(msg, 2);
- *UPB_PTR_AT(msg, UPB_SIZE(28, 40), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(32, 40), upb_StringView) = value;
}
UPB_INLINE void google_protobuf_FileOptions_set_optimize_for(google_protobuf_FileOptions *msg, int32_t value) {
_upb_sethas(msg, 3);
@@ -4381,7 +4379,7 @@
}
UPB_INLINE void google_protobuf_FileOptions_set_go_package(google_protobuf_FileOptions *msg, upb_StringView value) {
_upb_sethas(msg, 5);
- *UPB_PTR_AT(msg, UPB_SIZE(36, 56), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(40, 56), upb_StringView) = value;
}
UPB_INLINE void google_protobuf_FileOptions_set_cc_generic_services(google_protobuf_FileOptions *msg, bool value) {
_upb_sethas(msg, 6);
@@ -4413,23 +4411,23 @@
}
UPB_INLINE void google_protobuf_FileOptions_set_objc_class_prefix(google_protobuf_FileOptions *msg, upb_StringView value) {
_upb_sethas(msg, 13);
- *UPB_PTR_AT(msg, UPB_SIZE(44, 72), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(48, 72), upb_StringView) = value;
}
UPB_INLINE void google_protobuf_FileOptions_set_csharp_namespace(google_protobuf_FileOptions *msg, upb_StringView value) {
_upb_sethas(msg, 14);
- *UPB_PTR_AT(msg, UPB_SIZE(52, 88), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(56, 88), upb_StringView) = value;
}
UPB_INLINE void google_protobuf_FileOptions_set_swift_prefix(google_protobuf_FileOptions *msg, upb_StringView value) {
_upb_sethas(msg, 15);
- *UPB_PTR_AT(msg, UPB_SIZE(60, 104), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(64, 104), upb_StringView) = value;
}
UPB_INLINE void google_protobuf_FileOptions_set_php_class_prefix(google_protobuf_FileOptions *msg, upb_StringView value) {
_upb_sethas(msg, 16);
- *UPB_PTR_AT(msg, UPB_SIZE(68, 120), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(72, 120), upb_StringView) = value;
}
UPB_INLINE void google_protobuf_FileOptions_set_php_namespace(google_protobuf_FileOptions *msg, upb_StringView value) {
_upb_sethas(msg, 17);
- *UPB_PTR_AT(msg, UPB_SIZE(76, 136), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(80, 136), upb_StringView) = value;
}
UPB_INLINE void google_protobuf_FileOptions_set_php_generic_services(google_protobuf_FileOptions *msg, bool value) {
_upb_sethas(msg, 18);
@@ -4437,21 +4435,21 @@
}
UPB_INLINE void google_protobuf_FileOptions_set_php_metadata_namespace(google_protobuf_FileOptions *msg, upb_StringView value) {
_upb_sethas(msg, 19);
- *UPB_PTR_AT(msg, UPB_SIZE(84, 152), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(88, 152), upb_StringView) = value;
}
UPB_INLINE void google_protobuf_FileOptions_set_ruby_package(google_protobuf_FileOptions *msg, upb_StringView value) {
_upb_sethas(msg, 20);
- *UPB_PTR_AT(msg, UPB_SIZE(92, 168), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(96, 168), upb_StringView) = value;
}
UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_FileOptions_mutable_uninterpreted_option(google_protobuf_FileOptions* msg, size_t* len) {
- return (google_protobuf_UninterpretedOption**)_upb_array_mutable_accessor(msg, UPB_SIZE(100, 184), len);
+ return (google_protobuf_UninterpretedOption**)_upb_array_mutable_accessor(msg, UPB_SIZE(20, 184), len);
}
UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_FileOptions_resize_uninterpreted_option(google_protobuf_FileOptions* msg, size_t len, upb_Arena* arena) {
- return (google_protobuf_UninterpretedOption**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(100, 184), len, UPB_SIZE(2, 3), arena);
+ return (google_protobuf_UninterpretedOption**)_upb_Array_Resize_accessor2(msg, UPB_SIZE(20, 184), len, UPB_SIZE(2, 3), arena);
}
UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_FileOptions_add_uninterpreted_option(google_protobuf_FileOptions* msg, upb_Arena* arena) {
struct google_protobuf_UninterpretedOption* sub = (struct google_protobuf_UninterpretedOption*)_upb_Message_New(&google_protobuf_UninterpretedOption_msg_init, arena);
- bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(100, 184), UPB_SIZE(2, 3), &sub, arena);
+ bool ok = _upb_Array_Append_accessor2(msg, UPB_SIZE(20, 184), UPB_SIZE(2, 3), &sub, arena);
if (!ok) return NULL;
return sub;
}
@@ -5158,51 +5156,51 @@
return _upb_hasbit(msg, 2);
}
UPB_INLINE void google_protobuf_UninterpretedOption_clear_positive_int_value(const google_protobuf_UninterpretedOption* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(32, 64), uint64_t) = 0;
+ *UPB_PTR_AT(msg, UPB_SIZE(16, 32), uint64_t) = 0;
_upb_clearhas(msg, 2);
}
UPB_INLINE uint64_t google_protobuf_UninterpretedOption_positive_int_value(const google_protobuf_UninterpretedOption* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(32, 64), uint64_t);
+ return *UPB_PTR_AT(msg, UPB_SIZE(16, 32), uint64_t);
}
UPB_INLINE bool google_protobuf_UninterpretedOption_has_negative_int_value(const google_protobuf_UninterpretedOption* msg) {
return _upb_hasbit(msg, 3);
}
UPB_INLINE void google_protobuf_UninterpretedOption_clear_negative_int_value(const google_protobuf_UninterpretedOption* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(40, 72), int64_t) = 0;
+ *UPB_PTR_AT(msg, UPB_SIZE(24, 40), int64_t) = 0;
_upb_clearhas(msg, 3);
}
UPB_INLINE int64_t google_protobuf_UninterpretedOption_negative_int_value(const google_protobuf_UninterpretedOption* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(40, 72), int64_t);
+ return *UPB_PTR_AT(msg, UPB_SIZE(24, 40), int64_t);
}
UPB_INLINE bool google_protobuf_UninterpretedOption_has_double_value(const google_protobuf_UninterpretedOption* msg) {
return _upb_hasbit(msg, 4);
}
UPB_INLINE void google_protobuf_UninterpretedOption_clear_double_value(const google_protobuf_UninterpretedOption* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(48, 80), double) = 0;
+ *UPB_PTR_AT(msg, UPB_SIZE(32, 48), double) = 0;
_upb_clearhas(msg, 4);
}
UPB_INLINE double google_protobuf_UninterpretedOption_double_value(const google_protobuf_UninterpretedOption* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(48, 80), double);
+ return *UPB_PTR_AT(msg, UPB_SIZE(32, 48), double);
}
UPB_INLINE bool google_protobuf_UninterpretedOption_has_string_value(const google_protobuf_UninterpretedOption* msg) {
return _upb_hasbit(msg, 5);
}
UPB_INLINE void google_protobuf_UninterpretedOption_clear_string_value(const google_protobuf_UninterpretedOption* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(16, 32), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(40, 56), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 5);
}
UPB_INLINE upb_StringView google_protobuf_UninterpretedOption_string_value(const google_protobuf_UninterpretedOption* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(16, 32), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(40, 56), upb_StringView);
}
UPB_INLINE bool google_protobuf_UninterpretedOption_has_aggregate_value(const google_protobuf_UninterpretedOption* msg) {
return _upb_hasbit(msg, 6);
}
UPB_INLINE void google_protobuf_UninterpretedOption_clear_aggregate_value(const google_protobuf_UninterpretedOption* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(24, 48), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(48, 72), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 6);
}
UPB_INLINE upb_StringView google_protobuf_UninterpretedOption_aggregate_value(const google_protobuf_UninterpretedOption* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(24, 48), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(48, 72), upb_StringView);
}
UPB_INLINE google_protobuf_UninterpretedOption_NamePart** google_protobuf_UninterpretedOption_mutable_name(google_protobuf_UninterpretedOption* msg, size_t* len) {
@@ -5223,23 +5221,23 @@
}
UPB_INLINE void google_protobuf_UninterpretedOption_set_positive_int_value(google_protobuf_UninterpretedOption *msg, uint64_t value) {
_upb_sethas(msg, 2);
- *UPB_PTR_AT(msg, UPB_SIZE(32, 64), uint64_t) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(16, 32), uint64_t) = value;
}
UPB_INLINE void google_protobuf_UninterpretedOption_set_negative_int_value(google_protobuf_UninterpretedOption *msg, int64_t value) {
_upb_sethas(msg, 3);
- *UPB_PTR_AT(msg, UPB_SIZE(40, 72), int64_t) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(24, 40), int64_t) = value;
}
UPB_INLINE void google_protobuf_UninterpretedOption_set_double_value(google_protobuf_UninterpretedOption *msg, double value) {
_upb_sethas(msg, 4);
- *UPB_PTR_AT(msg, UPB_SIZE(48, 80), double) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(32, 48), double) = value;
}
UPB_INLINE void google_protobuf_UninterpretedOption_set_string_value(google_protobuf_UninterpretedOption *msg, upb_StringView value) {
_upb_sethas(msg, 5);
- *UPB_PTR_AT(msg, UPB_SIZE(16, 32), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(40, 56), upb_StringView) = value;
}
UPB_INLINE void google_protobuf_UninterpretedOption_set_aggregate_value(google_protobuf_UninterpretedOption *msg, upb_StringView value) {
_upb_sethas(msg, 6);
- *UPB_PTR_AT(msg, UPB_SIZE(24, 48), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(48, 72), upb_StringView) = value;
}
/* google.protobuf.UninterpretedOption.NamePart */
@@ -5416,27 +5414,27 @@
return _upb_hasbit(msg, 1);
}
UPB_INLINE void google_protobuf_SourceCodeInfo_Location_clear_leading_comments(const google_protobuf_SourceCodeInfo_Location* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(12, 24), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(16, 24), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 1);
}
UPB_INLINE upb_StringView google_protobuf_SourceCodeInfo_Location_leading_comments(const google_protobuf_SourceCodeInfo_Location* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(12, 24), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(16, 24), upb_StringView);
}
UPB_INLINE bool google_protobuf_SourceCodeInfo_Location_has_trailing_comments(const google_protobuf_SourceCodeInfo_Location* msg) {
return _upb_hasbit(msg, 2);
}
UPB_INLINE void google_protobuf_SourceCodeInfo_Location_clear_trailing_comments(const google_protobuf_SourceCodeInfo_Location* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(20, 40), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
+ *UPB_PTR_AT(msg, UPB_SIZE(24, 40), upb_StringView) = upb_StringView_FromDataAndSize(NULL, 0);
_upb_clearhas(msg, 2);
}
UPB_INLINE upb_StringView google_protobuf_SourceCodeInfo_Location_trailing_comments(const google_protobuf_SourceCodeInfo_Location* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(20, 40), upb_StringView);
+ return *UPB_PTR_AT(msg, UPB_SIZE(24, 40), upb_StringView);
}
UPB_INLINE void google_protobuf_SourceCodeInfo_Location_clear_leading_detached_comments(const google_protobuf_SourceCodeInfo_Location* msg) {
- _upb_array_detach(msg, UPB_SIZE(28, 56));
+ _upb_array_detach(msg, UPB_SIZE(12, 56));
}
UPB_INLINE upb_StringView const* google_protobuf_SourceCodeInfo_Location_leading_detached_comments(const google_protobuf_SourceCodeInfo_Location* msg, size_t* len) {
- return (upb_StringView const*)_upb_array_accessor(msg, UPB_SIZE(28, 56), len);
+ return (upb_StringView const*)_upb_array_accessor(msg, UPB_SIZE(12, 56), len);
}
UPB_INLINE int32_t* google_protobuf_SourceCodeInfo_Location_mutable_path(google_protobuf_SourceCodeInfo_Location* msg, size_t* len) {
@@ -5459,20 +5457,20 @@
}
UPB_INLINE void google_protobuf_SourceCodeInfo_Location_set_leading_comments(google_protobuf_SourceCodeInfo_Location *msg, upb_StringView value) {
_upb_sethas(msg, 1);
- *UPB_PTR_AT(msg, UPB_SIZE(12, 24), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(16, 24), upb_StringView) = value;
}
UPB_INLINE void google_protobuf_SourceCodeInfo_Location_set_trailing_comments(google_protobuf_SourceCodeInfo_Location *msg, upb_StringView value) {
_upb_sethas(msg, 2);
- *UPB_PTR_AT(msg, UPB_SIZE(20, 40), upb_StringView) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(24, 40), upb_StringView) = value;
}
UPB_INLINE upb_StringView* google_protobuf_SourceCodeInfo_Location_mutable_leading_detached_comments(google_protobuf_SourceCodeInfo_Location* msg, size_t* len) {
- return (upb_StringView*)_upb_array_mutable_accessor(msg, UPB_SIZE(28, 56), len);
+ return (upb_StringView*)_upb_array_mutable_accessor(msg, UPB_SIZE(12, 56), len);
}
UPB_INLINE upb_StringView* google_protobuf_SourceCodeInfo_Location_resize_leading_detached_comments(google_protobuf_SourceCodeInfo_Location* msg, size_t len, upb_Arena* arena) {
- return (upb_StringView*)_upb_Array_Resize_accessor2(msg, UPB_SIZE(28, 56), len, UPB_SIZE(3, 4), arena);
+ return (upb_StringView*)_upb_Array_Resize_accessor2(msg, UPB_SIZE(12, 56), len, UPB_SIZE(3, 4), arena);
}
UPB_INLINE bool google_protobuf_SourceCodeInfo_Location_add_leading_detached_comments(google_protobuf_SourceCodeInfo_Location* msg, upb_StringView val, upb_Arena* arena) {
- return _upb_Array_Append_accessor2(msg, UPB_SIZE(28, 56), UPB_SIZE(3, 4), &val, arena);
+ return _upb_Array_Append_accessor2(msg, UPB_SIZE(12, 56), UPB_SIZE(3, 4), &val, arena);
}
/* google.protobuf.GeneratedCodeInfo */
@@ -5569,10 +5567,10 @@
return ptr;
}
UPB_INLINE void google_protobuf_GeneratedCodeInfo_Annotation_clear_path(const google_protobuf_GeneratedCodeInfo_Annotation* msg) {
- _upb_array_detach(msg, UPB_SIZE(16, 16));
+ _upb_array_detach(msg, UPB_SIZE(4, 16));
}
UPB_INLINE int32_t const* google_protobuf_GeneratedCodeInfo_Annotation_path(const google_protobuf_GeneratedCodeInfo_Annotation* msg, size_t* len) {
- return (int32_t const*)_upb_array_accessor(msg, UPB_SIZE(16, 16), len);
+ return (int32_t const*)_upb_array_accessor(msg, UPB_SIZE(4, 16), len);
}
UPB_INLINE bool google_protobuf_GeneratedCodeInfo_Annotation_has_source_file(const google_protobuf_GeneratedCodeInfo_Annotation* msg) {
return _upb_hasbit(msg, 1);
@@ -5588,41 +5586,41 @@
return _upb_hasbit(msg, 2);
}
UPB_INLINE void google_protobuf_GeneratedCodeInfo_Annotation_clear_begin(const google_protobuf_GeneratedCodeInfo_Annotation* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(4, 4), int32_t) = 0;
+ *UPB_PTR_AT(msg, UPB_SIZE(8, 4), int32_t) = 0;
_upb_clearhas(msg, 2);
}
UPB_INLINE int32_t google_protobuf_GeneratedCodeInfo_Annotation_begin(const google_protobuf_GeneratedCodeInfo_Annotation* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(4, 4), int32_t);
+ return *UPB_PTR_AT(msg, UPB_SIZE(8, 4), int32_t);
}
UPB_INLINE bool google_protobuf_GeneratedCodeInfo_Annotation_has_end(const google_protobuf_GeneratedCodeInfo_Annotation* msg) {
return _upb_hasbit(msg, 3);
}
UPB_INLINE void google_protobuf_GeneratedCodeInfo_Annotation_clear_end(const google_protobuf_GeneratedCodeInfo_Annotation* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(8, 8), int32_t) = 0;
+ *UPB_PTR_AT(msg, UPB_SIZE(12, 8), int32_t) = 0;
_upb_clearhas(msg, 3);
}
UPB_INLINE int32_t google_protobuf_GeneratedCodeInfo_Annotation_end(const google_protobuf_GeneratedCodeInfo_Annotation* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(8, 8), int32_t);
+ return *UPB_PTR_AT(msg, UPB_SIZE(12, 8), int32_t);
}
UPB_INLINE bool google_protobuf_GeneratedCodeInfo_Annotation_has_semantic(const google_protobuf_GeneratedCodeInfo_Annotation* msg) {
return _upb_hasbit(msg, 4);
}
UPB_INLINE void google_protobuf_GeneratedCodeInfo_Annotation_clear_semantic(const google_protobuf_GeneratedCodeInfo_Annotation* msg) {
- *UPB_PTR_AT(msg, UPB_SIZE(12, 12), int32_t) = 0;
+ *UPB_PTR_AT(msg, UPB_SIZE(16, 12), int32_t) = 0;
_upb_clearhas(msg, 4);
}
UPB_INLINE int32_t google_protobuf_GeneratedCodeInfo_Annotation_semantic(const google_protobuf_GeneratedCodeInfo_Annotation* msg) {
- return *UPB_PTR_AT(msg, UPB_SIZE(12, 12), int32_t);
+ return *UPB_PTR_AT(msg, UPB_SIZE(16, 12), int32_t);
}
UPB_INLINE int32_t* google_protobuf_GeneratedCodeInfo_Annotation_mutable_path(google_protobuf_GeneratedCodeInfo_Annotation* msg, size_t* len) {
- return (int32_t*)_upb_array_mutable_accessor(msg, UPB_SIZE(16, 16), len);
+ return (int32_t*)_upb_array_mutable_accessor(msg, UPB_SIZE(4, 16), len);
}
UPB_INLINE int32_t* google_protobuf_GeneratedCodeInfo_Annotation_resize_path(google_protobuf_GeneratedCodeInfo_Annotation* msg, size_t len, upb_Arena* arena) {
- return (int32_t*)_upb_Array_Resize_accessor2(msg, UPB_SIZE(16, 16), len, 2, arena);
+ return (int32_t*)_upb_Array_Resize_accessor2(msg, UPB_SIZE(4, 16), len, 2, arena);
}
UPB_INLINE bool google_protobuf_GeneratedCodeInfo_Annotation_add_path(google_protobuf_GeneratedCodeInfo_Annotation* msg, int32_t val, upb_Arena* arena) {
- return _upb_Array_Append_accessor2(msg, UPB_SIZE(16, 16), 2, &val, arena);
+ return _upb_Array_Append_accessor2(msg, UPB_SIZE(4, 16), 2, &val, arena);
}
UPB_INLINE void google_protobuf_GeneratedCodeInfo_Annotation_set_source_file(google_protobuf_GeneratedCodeInfo_Annotation *msg, upb_StringView value) {
_upb_sethas(msg, 1);
@@ -5630,15 +5628,15 @@
}
UPB_INLINE void google_protobuf_GeneratedCodeInfo_Annotation_set_begin(google_protobuf_GeneratedCodeInfo_Annotation *msg, int32_t value) {
_upb_sethas(msg, 2);
- *UPB_PTR_AT(msg, UPB_SIZE(4, 4), int32_t) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(8, 4), int32_t) = value;
}
UPB_INLINE void google_protobuf_GeneratedCodeInfo_Annotation_set_end(google_protobuf_GeneratedCodeInfo_Annotation *msg, int32_t value) {
_upb_sethas(msg, 3);
- *UPB_PTR_AT(msg, UPB_SIZE(8, 8), int32_t) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(12, 8), int32_t) = value;
}
UPB_INLINE void google_protobuf_GeneratedCodeInfo_Annotation_set_semantic(google_protobuf_GeneratedCodeInfo_Annotation *msg, int32_t value) {
_upb_sethas(msg, 4);
- *UPB_PTR_AT(msg, UPB_SIZE(12, 12), int32_t) = value;
+ *UPB_PTR_AT(msg, UPB_SIZE(16, 12), int32_t) = value;
}
extern const upb_MiniTable_File google_protobuf_descriptor_proto_upb_file_layout;
@@ -5999,12 +5997,19 @@
const char* name,
size_t len);
-const upb_FieldDef* upb_DefPool_FindExtensionByNameWithSize(
- const upb_DefPool* s, const char* name, size_t size);
+const upb_FieldDef* upb_DefPool_FindExtensionByMiniTable(
+ const upb_DefPool* s, const upb_MiniTable_Extension* ext);
const upb_FieldDef* upb_DefPool_FindExtensionByName(const upb_DefPool* s,
const char* sym);
+const upb_FieldDef* upb_DefPool_FindExtensionByNameWithSize(
+ const upb_DefPool* s, const char* name, size_t size);
+
+const upb_FieldDef* upb_DefPool_FindExtensionByNumber(const upb_DefPool* s,
+ const upb_MessageDef* m,
+ int32_t fieldnum);
+
const upb_ServiceDef* upb_DefPool_FindServiceByName(const upb_DefPool* s,
const char* name);
@@ -6018,10 +6023,6 @@
upb_DefPool* s, const google_protobuf_FileDescriptorProto* file_proto,
upb_Status* status);
-const upb_FieldDef* upb_DefPool_FindExtensionByNumber(const upb_DefPool* s,
- const upb_MessageDef* m,
- int32_t fieldnum);
-
const upb_ExtensionRegistry* upb_DefPool_ExtensionRegistry(
const upb_DefPool* s);
@@ -6029,39 +6030,6 @@
const upb_MessageDef* m,
size_t* count);
-// EVERYTHING BELOW THIS LINE IS INTERNAL - DO NOT USE /////////////////////////
-
-upb_Arena* _upb_DefPool_Arena(const upb_DefPool* s);
-size_t _upb_DefPool_BytesLoaded(const upb_DefPool* s);
-upb_ExtensionRegistry* _upb_DefPool_ExtReg(const upb_DefPool* s);
-const upb_FieldDef* _upb_DefPool_FindExtensionByMiniTable(
- const upb_DefPool* s, const upb_MiniTable_Extension* ext);
-
-bool _upb_DefPool_InsertExt(upb_DefPool* s, const upb_MiniTable_Extension* ext,
- upb_FieldDef* f);
-bool _upb_DefPool_InsertSym(upb_DefPool* s, upb_StringView sym, upb_value v,
- upb_Status* status);
-bool _upb_DefPool_LookupSym(const upb_DefPool* s, const char* sym, size_t size,
- upb_value* v);
-
-void** _upb_DefPool_ScratchData(const upb_DefPool* s);
-size_t* _upb_DefPool_ScratchSize(const upb_DefPool* s);
-
-// For generated code only: loads a generated descriptor.
-typedef struct _upb_DefPool_Init {
- struct _upb_DefPool_Init** deps; // Dependencies of this file.
- const upb_MiniTable_File* layout;
- const char* filename;
- upb_StringView descriptor; // Serialized descriptor.
-} _upb_DefPool_Init;
-
-bool _upb_DefPool_LoadDefInit(upb_DefPool* s, const _upb_DefPool_Init* init);
-
-// Should only be directly called by tests. This variant lets us suppress
-// the use of compiled-in tables, forcing a rebuild of the tables at runtime.
-bool _upb_DefPool_LoadDefInitEx(upb_DefPool* s, const _upb_DefPool_Init* init,
- bool rebuild_minitable);
-
#ifdef __cplusplus
} /* extern "C" */
#endif
@@ -6093,6 +6061,7 @@
int32_t num);
const char* upb_EnumDef_FullName(const upb_EnumDef* e);
bool upb_EnumDef_HasOptions(const upb_EnumDef* e);
+bool upb_EnumDef_IsClosed(const upb_EnumDef* e);
// Creates a mini descriptor string for an enum, returns true on success.
bool upb_EnumDef_MiniDescriptorEncode(const upb_EnumDef* e, upb_Arena* a,
@@ -6103,17 +6072,6 @@
const upb_EnumValueDef* upb_EnumDef_Value(const upb_EnumDef* e, int i);
int upb_EnumDef_ValueCount(const upb_EnumDef* e);
-// EVERYTHING BELOW THIS LINE IS INTERNAL - DO NOT USE /////////////////////////
-
-upb_EnumDef* _upb_EnumDef_At(const upb_EnumDef* e, int i);
-bool _upb_EnumDef_Insert(upb_EnumDef* e, upb_EnumValueDef* v, upb_Arena* a);
-const upb_MiniTable_Enum* _upb_EnumDef_MiniTable(const upb_EnumDef* e);
-
-// Allocate and initialize an array of |n| enum defs.
-upb_EnumDef* _upb_EnumDefs_New(upb_DefBuilder* ctx, int n,
- const google_protobuf_EnumDescriptorProto* const* protos,
- const upb_MessageDef* containing_type);
-
#ifdef __cplusplus
} /* extern "C" */
#endif
@@ -6142,19 +6100,6 @@
const google_protobuf_EnumValueOptions* upb_EnumValueDef_Options(
const upb_EnumValueDef* v);
-// EVERYTHING BELOW THIS LINE IS INTERNAL - DO NOT USE /////////////////////////
-
-upb_EnumValueDef* _upb_EnumValueDef_At(const upb_EnumValueDef* v, int i);
-
-// Allocate and initialize an array of |n| enum value defs owned by |e|.
-upb_EnumValueDef* _upb_EnumValueDefs_New(
- upb_DefBuilder* ctx, const char* prefix, int n,
- const google_protobuf_EnumValueDescriptorProto* const* protos, upb_EnumDef* e,
- bool* is_sorted);
-
-const upb_EnumValueDef** _upb_EnumValueDefs_Sorted(const upb_EnumValueDef* v,
- int n, upb_Arena* a);
-
#ifdef __cplusplus
} /* extern "C" */
#endif
@@ -6181,16 +6126,6 @@
const google_protobuf_ExtensionRangeOptions* upb_ExtensionRange_Options(
const upb_ExtensionRange* r);
-// EVERYTHING BELOW THIS LINE IS INTERNAL - DO NOT USE /////////////////////////
-
-upb_ExtensionRange* _upb_ExtensionRange_At(const upb_ExtensionRange* r, int i);
-
-// Allocate and initialize an array of |n| extension ranges owned by |m|.
-upb_ExtensionRange* _upb_ExtensionRanges_New(
- upb_DefBuilder* ctx, int n,
- const google_protobuf_DescriptorProto_ExtensionRange* const* protos,
- const upb_MessageDef* m);
-
#ifdef __cplusplus
} /* extern "C" */
#endif
@@ -6251,30 +6186,6 @@
const upb_OneofDef* upb_FieldDef_RealContainingOneof(const upb_FieldDef* f);
upb_FieldType upb_FieldDef_Type(const upb_FieldDef* f);
-// EVERYTHING BELOW THIS LINE IS INTERNAL - DO NOT USE /////////////////////////
-
-upb_FieldDef* _upb_FieldDef_At(const upb_FieldDef* f, int i);
-
-const upb_MiniTable_Extension* _upb_FieldDef_ExtensionMiniTable(
- const upb_FieldDef* f);
-bool _upb_FieldDef_IsClosedEnum(const upb_FieldDef* f);
-bool _upb_FieldDef_IsProto3Optional(const upb_FieldDef* f);
-int _upb_FieldDef_LayoutIndex(const upb_FieldDef* f);
-uint64_t _upb_FieldDef_Modifiers(const upb_FieldDef* f);
-void _upb_FieldDef_Resolve(upb_DefBuilder* ctx, const char* prefix,
- upb_FieldDef* f);
-
-// Allocate and initialize an array of |n| field defs.
-upb_FieldDef* _upb_FieldDefs_New(
- upb_DefBuilder* ctx, int n,
- const google_protobuf_FieldDescriptorProto* const* protos, const char* prefix,
- upb_MessageDef* m, bool* is_sorted);
-
-// Allocate and return a list of pointers to the |n| field defs in |ff|,
-// sorted by field number.
-const upb_FieldDef** _upb_FieldDefs_Sorted(const upb_FieldDef* f, int n,
- upb_Arena* a);
-
#ifdef __cplusplus
} /* extern "C" */
#endif
@@ -6322,19 +6233,6 @@
const upb_FileDef* upb_FileDef_WeakDependency(const upb_FileDef* f, int i);
int upb_FileDef_WeakDependencyCount(const upb_FileDef* f);
-// EVERYTHING BELOW THIS LINE IS INTERNAL - DO NOT USE /////////////////////////
-
-const upb_MiniTable_Extension* _upb_FileDef_ExtensionMiniTable(
- const upb_FileDef* f, int i);
-const int32_t* _upb_FileDef_PublicDependencyIndexes(const upb_FileDef* f);
-const int32_t* _upb_FileDef_WeakDependencyIndexes(const upb_FileDef* f);
-
-// upb_FileDef_Package() returns "" if f->package is NULL, this does not.
-const char* _upb_FileDef_RawPackage(const upb_FileDef* f);
-
-void _upb_FileDef_Create(upb_DefBuilder* ctx,
- const google_protobuf_FileDescriptorProto* file_proto);
-
#ifdef __cplusplus
} /* extern "C" */
#endif
@@ -6469,24 +6367,6 @@
upb_Syntax upb_MessageDef_Syntax(const upb_MessageDef* m);
upb_WellKnown upb_MessageDef_WellKnownType(const upb_MessageDef* m);
-// EVERYTHING BELOW THIS LINE IS INTERNAL - DO NOT USE /////////////////////////
-
-upb_MessageDef* _upb_MessageDef_At(const upb_MessageDef* m, int i);
-bool _upb_MessageDef_InMessageSet(const upb_MessageDef* m);
-bool _upb_MessageDef_Insert(upb_MessageDef* m, const char* name, size_t size,
- upb_value v, upb_Arena* a);
-void _upb_MessageDef_InsertField(upb_DefBuilder* ctx, upb_MessageDef* m,
- const upb_FieldDef* f);
-bool _upb_MessageDef_IsValidExtensionNumber(const upb_MessageDef* m, int n);
-void _upb_MessageDef_LinkMiniTable(upb_DefBuilder* ctx,
- const upb_MessageDef* m);
-void _upb_MessageDef_Resolve(upb_DefBuilder* ctx, upb_MessageDef* m);
-
-// Allocate and initialize an array of |n| message defs.
-upb_MessageDef* _upb_MessageDefs_New(
- upb_DefBuilder* ctx, int n, const google_protobuf_DescriptorProto* const* protos,
- const upb_MessageDef* containing_type);
-
#ifdef __cplusplus
} /* extern "C" */
#endif
@@ -6517,15 +6397,6 @@
bool upb_MethodDef_ServerStreaming(const upb_MethodDef* m);
const upb_ServiceDef* upb_MethodDef_Service(const upb_MethodDef* m);
-// EVERYTHING BELOW THIS LINE IS INTERNAL - DO NOT USE /////////////////////////
-
-upb_MethodDef* _upb_MethodDef_At(const upb_MethodDef* m, int i);
-
-// Allocate and initialize an array of |n| method defs owned by |s|.
-upb_MethodDef* _upb_MethodDefs_New(
- upb_DefBuilder* ctx, int n,
- const google_protobuf_MethodDescriptorProto* const* protos, upb_ServiceDef* s);
-
#ifdef __cplusplus
} /* extern "C" */
#endif
@@ -6563,19 +6434,6 @@
int upb_OneofDef_numfields(const upb_OneofDef* o);
const google_protobuf_OneofOptions* upb_OneofDef_Options(const upb_OneofDef* o);
-// EVERYTHING BELOW THIS LINE IS INTERNAL - DO NOT USE /////////////////////////
-
-upb_OneofDef* _upb_OneofDef_At(const upb_OneofDef* o, int i);
-bool _upb_OneofDef_Insert(upb_OneofDef* o, const upb_FieldDef* f,
- const char* name, size_t size, upb_Arena* a);
-
-// Allocate and initialize an array of |n| oneof defs owned by |m|.
-upb_OneofDef* _upb_OneofDefs_New(
- upb_DefBuilder* ctx, int n,
- const google_protobuf_OneofDescriptorProto* const* protos, upb_MessageDef* m);
-
-size_t _upb_OneofDefs_Finalize(upb_DefBuilder* ctx, upb_MessageDef* m);
-
#ifdef __cplusplus
} /* extern "C" */
#endif
@@ -6606,15 +6464,6 @@
const char* upb_ServiceDef_Name(const upb_ServiceDef* s);
const google_protobuf_ServiceOptions* upb_ServiceDef_Options(const upb_ServiceDef* s);
-// EVERYTHING BELOW THIS LINE IS INTERNAL - DO NOT USE /////////////////////////
-
-upb_ServiceDef* _upb_ServiceDef_At(const upb_ServiceDef* s, int i);
-
-// Allocate and initialize an array of |n| service defs.
-upb_ServiceDef* _upb_ServiceDefs_New(
- upb_DefBuilder* ctx, int n,
- const google_protobuf_ServiceDescriptorProto* const* protos);
-
#ifdef __cplusplus
} /* extern "C" */
#endif
@@ -6704,9 +6553,6 @@
upb_MessageValue upb_FieldDef_Default(const upb_FieldDef* f);
-/* Creates a new message of the given type in the given arena. */
-upb_Message* upb_Message_New(const upb_MessageDef* m, upb_Arena* a);
-
/* Returns the value associated with this field. */
upb_MessageValue upb_Message_Get(const upb_Message* msg, const upb_FieldDef* f);
@@ -6872,6 +6718,8 @@
const upb_MiniTable_Field* upb_MiniTable_FindFieldByNumber(
const upb_MiniTable* table, uint32_t number);
+upb_FieldType upb_MiniTableField_Type(const upb_MiniTable_Field* field);
+
UPB_INLINE const upb_MiniTable* upb_MiniTable_GetSubMessageTable(
const upb_MiniTable* mini_table, const upb_MiniTable_Field* field) {
return mini_table->subs[field->submsg_index].submsg;
@@ -6944,13 +6792,18 @@
char* upb_MtDataEncoder_PutOneofField(upb_MtDataEncoder* e, char* ptr,
uint32_t field_num);
-// Encodes the set of values for a given enum. The values must be given in
+// Encodes the set of values for a given enum. The values must be given in
// order (after casting to uint32_t), and repeats are not allowed.
-void upb_MtDataEncoder_StartEnum(upb_MtDataEncoder* e);
+char* upb_MtDataEncoder_StartEnum(upb_MtDataEncoder* e, char* ptr);
char* upb_MtDataEncoder_PutEnumValue(upb_MtDataEncoder* e, char* ptr,
uint32_t val);
char* upb_MtDataEncoder_EndEnum(upb_MtDataEncoder* e, char* ptr);
+// Encodes an entire mini descriptor for one extension.
+char* upb_MtDataEncoder_EncodeExtension(upb_MtDataEncoder* e, char* ptr,
+ upb_FieldType type, uint32_t field_num,
+ uint64_t field_mod);
+
/** upb_MiniTable *************************************************************/
typedef enum {
@@ -7025,15 +6878,61 @@
#endif /* UPB_MINI_TABLE_H_ */
-#ifndef UPB_REFLECTION_DEF_BUILDER_H_
-#define UPB_REFLECTION_DEF_BUILDER_H_
+#ifndef UPB_REFLECTION_DEF_BUILDER_INTERNAL_H_
+#define UPB_REFLECTION_DEF_BUILDER_INTERNAL_H_
+#ifndef UPB_REFLECTION_DEF_POOL_INTERNAL_H_
+#define UPB_REFLECTION_DEF_POOL_INTERNAL_H_
+
+
+// Must be last.
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+upb_Arena* _upb_DefPool_Arena(const upb_DefPool* s);
+size_t _upb_DefPool_BytesLoaded(const upb_DefPool* s);
+upb_ExtensionRegistry* _upb_DefPool_ExtReg(const upb_DefPool* s);
+
+bool _upb_DefPool_InsertExt(upb_DefPool* s, const upb_MiniTable_Extension* ext,
+ upb_FieldDef* f);
+bool _upb_DefPool_InsertSym(upb_DefPool* s, upb_StringView sym, upb_value v,
+ upb_Status* status);
+bool _upb_DefPool_LookupSym(const upb_DefPool* s, const char* sym, size_t size,
+ upb_value* v);
+
+void** _upb_DefPool_ScratchData(const upb_DefPool* s);
+size_t* _upb_DefPool_ScratchSize(const upb_DefPool* s);
+
+// For generated code only: loads a generated descriptor.
+typedef struct _upb_DefPool_Init {
+ struct _upb_DefPool_Init** deps; // Dependencies of this file.
+ const upb_MiniTable_File* layout;
+ const char* filename;
+ upb_StringView descriptor; // Serialized descriptor.
+} _upb_DefPool_Init;
+
+bool _upb_DefPool_LoadDefInit(upb_DefPool* s, const _upb_DefPool_Init* init);
+
+// Should only be directly called by tests. This variant lets us suppress
+// the use of compiled-in tables, forcing a rebuild of the tables at runtime.
+bool _upb_DefPool_LoadDefInitEx(upb_DefPool* s, const _upb_DefPool_Init* init,
+ bool rebuild_minitable);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+
+#endif /* UPB_REFLECTION_DEF_POOL_INTERNAL_H_ */
+
// Must be last.
// We want to copy the options verbatim into the destination options proto.
// We use serialize+parse as our deep copy.
-#define UBP_DEF_SET_OPTIONS(target, desc_type, options_type, proto) \
+#define UPB_DEF_SET_OPTIONS(target, desc_type, options_type, proto) \
if (google_protobuf_##desc_type##_has_options(proto)) { \
size_t size; \
char* pb = google_protobuf_##options_type##_serialize( \
@@ -7165,10 +7064,188 @@
#endif
-#endif /* UPB_REFLECTION_DEF_BUILDER_H_ */
+#endif /* UPB_REFLECTION_DEF_BUILDER_INTERNAL_H_ */
-#ifndef UPB_REFLECTION_DESC_STATE_H_
-#define UPB_REFLECTION_DESC_STATE_H_
+#ifndef UPB_REFLECTION_ENUM_DEF_INTERNAL_H_
+#define UPB_REFLECTION_ENUM_DEF_INTERNAL_H_
+
+
+// Must be last.
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+upb_EnumDef* _upb_EnumDef_At(const upb_EnumDef* e, int i);
+bool _upb_EnumDef_Insert(upb_EnumDef* e, upb_EnumValueDef* v, upb_Arena* a);
+const upb_MiniTable_Enum* _upb_EnumDef_MiniTable(const upb_EnumDef* e);
+
+// Allocate and initialize an array of |n| enum defs.
+upb_EnumDef* _upb_EnumDefs_New(upb_DefBuilder* ctx, int n,
+ const google_protobuf_EnumDescriptorProto* const* protos,
+ const upb_MessageDef* containing_type);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+
+#endif /* UPB_REFLECTION_ENUM_DEF_INTERNAL_H_ */
+
+#ifndef UPB_REFLECTION_ENUM_VALUE_DEF_INTERNAL_H_
+#define UPB_REFLECTION_ENUM_VALUE_DEF_INTERNAL_H_
+
+
+// Must be last.
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+upb_EnumValueDef* _upb_EnumValueDef_At(const upb_EnumValueDef* v, int i);
+
+// Allocate and initialize an array of |n| enum value defs owned by |e|.
+upb_EnumValueDef* _upb_EnumValueDefs_New(
+ upb_DefBuilder* ctx, const char* prefix, int n,
+ const google_protobuf_EnumValueDescriptorProto* const* protos, upb_EnumDef* e,
+ bool* is_sorted);
+
+const upb_EnumValueDef** _upb_EnumValueDefs_Sorted(const upb_EnumValueDef* v,
+ int n, upb_Arena* a);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+
+#endif /* UPB_REFLECTION_ENUM_VALUE_DEF_INTERNAL_H_ */
+
+#ifndef UPB_REFLECTION_FIELD_DEF_INTERNAL_H_
+#define UPB_REFLECTION_FIELD_DEF_INTERNAL_H_
+
+
+// Must be last.
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+upb_FieldDef* _upb_FieldDef_At(const upb_FieldDef* f, int i);
+
+const upb_MiniTable_Extension* _upb_FieldDef_ExtensionMiniTable(
+ const upb_FieldDef* f);
+bool _upb_FieldDef_IsClosedEnum(const upb_FieldDef* f);
+bool _upb_FieldDef_IsProto3Optional(const upb_FieldDef* f);
+int _upb_FieldDef_LayoutIndex(const upb_FieldDef* f);
+uint64_t _upb_FieldDef_Modifiers(const upb_FieldDef* f);
+void _upb_FieldDef_Resolve(upb_DefBuilder* ctx, const char* prefix,
+ upb_FieldDef* f);
+
+// Allocate and initialize an array of |n| field defs.
+upb_FieldDef* _upb_FieldDefs_New(
+ upb_DefBuilder* ctx, int n,
+ const google_protobuf_FieldDescriptorProto* const* protos, const char* prefix,
+ upb_MessageDef* m, bool* is_sorted);
+
+// Allocate and return a list of pointers to the |n| field defs in |ff|,
+// sorted by field number.
+const upb_FieldDef** _upb_FieldDefs_Sorted(const upb_FieldDef* f, int n,
+ upb_Arena* a);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+
+#endif /* UPB_REFLECTION_FIELD_DEF_INTERNAL_H_ */
+
+#ifndef UPB_REFLECTION_FILE_DEF_INTERNAL_H_
+#define UPB_REFLECTION_FILE_DEF_INTERNAL_H_
+
+
+// Must be last.
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+const upb_MiniTable_Extension* _upb_FileDef_ExtensionMiniTable(
+ const upb_FileDef* f, int i);
+const int32_t* _upb_FileDef_PublicDependencyIndexes(const upb_FileDef* f);
+const int32_t* _upb_FileDef_WeakDependencyIndexes(const upb_FileDef* f);
+
+// upb_FileDef_Package() returns "" if f->package is NULL, this does not.
+const char* _upb_FileDef_RawPackage(const upb_FileDef* f);
+
+void _upb_FileDef_Create(upb_DefBuilder* ctx,
+ const google_protobuf_FileDescriptorProto* file_proto);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+
+#endif /* UPB_REFLECTION_FILE_DEF_INTERNAL_H_ */
+
+#ifndef UPB_REFLECTION_MESSAGE_DEF_INTERNAL_H_
+#define UPB_REFLECTION_MESSAGE_DEF_INTERNAL_H_
+
+
+// Must be last.
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+upb_MessageDef* _upb_MessageDef_At(const upb_MessageDef* m, int i);
+bool _upb_MessageDef_InMessageSet(const upb_MessageDef* m);
+bool _upb_MessageDef_Insert(upb_MessageDef* m, const char* name, size_t size,
+ upb_value v, upb_Arena* a);
+void _upb_MessageDef_InsertField(upb_DefBuilder* ctx, upb_MessageDef* m,
+ const upb_FieldDef* f);
+bool _upb_MessageDef_IsValidExtensionNumber(const upb_MessageDef* m, int n);
+void _upb_MessageDef_LinkMiniTable(upb_DefBuilder* ctx,
+ const upb_MessageDef* m);
+void _upb_MessageDef_Resolve(upb_DefBuilder* ctx, upb_MessageDef* m);
+
+// Allocate and initialize an array of |n| message defs.
+upb_MessageDef* _upb_MessageDefs_New(
+ upb_DefBuilder* ctx, int n, const google_protobuf_DescriptorProto* const* protos,
+ const upb_MessageDef* containing_type);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+
+#endif /* UPB_REFLECTION_MESSAGE_DEF_INTERNAL_H_ */
+
+#ifndef UPB_REFLECTION_SERVICE_DEF_INTERNAL_H_
+#define UPB_REFLECTION_SERVICE_DEF_INTERNAL_H_
+
+
+// Must be last.
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+upb_ServiceDef* _upb_ServiceDef_At(const upb_ServiceDef* s, int i);
+
+// Allocate and initialize an array of |n| service defs.
+upb_ServiceDef* _upb_ServiceDefs_New(
+ upb_DefBuilder* ctx, int n,
+ const google_protobuf_ServiceDescriptorProto* const* protos);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+
+#endif /* UPB_REFLECTION_SERVICE_DEF_INTERNAL_H_ */
+
+#ifndef UPB_REFLECTION_DESC_STATE_INTERNAL_H_
+#define UPB_REFLECTION_DESC_STATE_INTERNAL_H_
// Must be last.
@@ -7199,7 +7276,84 @@
#endif
-#endif /* UPB_REFLECTION_DESC_STATE_H_ */
+#endif /* UPB_REFLECTION_DESC_STATE_INTERNAL_H_ */
+
+#ifndef UPB_REFLECTION_EXTENSION_RANGE_INTERNAL_H_
+#define UPB_REFLECTION_EXTENSION_RANGE_INTERNAL_H_
+
+
+// Must be last.
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+upb_ExtensionRange* _upb_ExtensionRange_At(const upb_ExtensionRange* r, int i);
+
+// Allocate and initialize an array of |n| extension ranges owned by |m|.
+upb_ExtensionRange* _upb_ExtensionRanges_New(
+ upb_DefBuilder* ctx, int n,
+ const google_protobuf_DescriptorProto_ExtensionRange* const* protos,
+ const upb_MessageDef* m);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+
+#endif /* UPB_REFLECTION_EXTENSION_RANGE_INTERNAL_H_ */
+
+#ifndef UPB_REFLECTION_ONEOF_DEF_INTERNAL_H_
+#define UPB_REFLECTION_ONEOF_DEF_INTERNAL_H_
+
+
+// Must be last.
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+upb_OneofDef* _upb_OneofDef_At(const upb_OneofDef* o, int i);
+bool _upb_OneofDef_Insert(upb_OneofDef* o, const upb_FieldDef* f,
+ const char* name, size_t size, upb_Arena* a);
+
+// Allocate and initialize an array of |n| oneof defs owned by |m|.
+upb_OneofDef* _upb_OneofDefs_New(
+ upb_DefBuilder* ctx, int n,
+ const google_protobuf_OneofDescriptorProto* const* protos, upb_MessageDef* m);
+
+size_t _upb_OneofDefs_Finalize(upb_DefBuilder* ctx, upb_MessageDef* m);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+
+#endif /* UPB_REFLECTION_ONEOF_DEF_INTERNAL_H_ */
+
+#ifndef UPB_REFLECTION_METHOD_DEF_INTERNAL_H_
+#define UPB_REFLECTION_METHOD_DEF_INTERNAL_H_
+
+
+// Must be last.
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+upb_MethodDef* _upb_MethodDef_At(const upb_MethodDef* m, int i);
+
+// Allocate and initialize an array of |n| method defs owned by |s|.
+upb_MethodDef* _upb_MethodDefs_New(
+ upb_DefBuilder* ctx, int n,
+ const google_protobuf_MethodDescriptorProto* const* protos, upb_ServiceDef* s);
+
+#ifdef __cplusplus
+} /* extern "C" */
+#endif
+
+
+#endif /* UPB_REFLECTION_METHOD_DEF_INTERNAL_H_ */
// EVERYTHING BELOW THIS LINE IS INTERNAL - DO NOT USE /////////////////////////