From cd9ee31352d5d416bdc27d9305a3f800faf9eb9a Mon Sep 17 00:00:00 2001 From: Joshua Haberman Date: Wed, 29 Oct 2025 10:58:44 -0700 Subject: [PATCH] Migrated to upb C code generator to Emit APIs. PiperOrigin-RevId: 825620726 --- .../stage0/google/protobuf/descriptor.upb.c | 674 +++- .../stage0/google/protobuf/descriptor.upb.h | 2867 ++++++++++------- upb_generator/c/BUILD | 4 +- upb_generator/c/generator.cc | 1039 +++--- .../google/protobuf/compiler/plugin.upb.c | 44 +- .../google/protobuf/compiler/plugin.upb.h | 309 +- 6 files changed, 3080 insertions(+), 1857 deletions(-) diff --git a/upb/reflection/stage0/google/protobuf/descriptor.upb.c b/upb/reflection/stage0/google/protobuf/descriptor.upb.c index 85d600739b75b..0b955bdd76f31 100644 --- a/upb/reflection/stage0/google/protobuf/descriptor.upb.c +++ b/upb/reflection/stage0/google/protobuf/descriptor.upb.c @@ -21,8 +21,12 @@ const upb_MiniTable* google__protobuf__FileDescriptorSet_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 1), google__protobuf__FileDescriptorProto_msg_init()); - return mini_table; + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 1), + google__protobuf__FileDescriptorProto_msg_init()); + return mini_table; } const upb_MiniTable* google__protobuf__FileDescriptorProto_msg_init() { @@ -38,14 +42,42 @@ const upb_MiniTable* google__protobuf__FileDescriptorProto_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 4), google__protobuf__DescriptorProto_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 5), google__protobuf__EnumDescriptorProto_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 6), google__protobuf__ServiceDescriptorProto_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 7), google__protobuf__FieldDescriptorProto_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 8), google__protobuf__FileOptions_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 9), google__protobuf__SourceCodeInfo_msg_init()); - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 14), google__protobuf__Edition_enum_init()); - return mini_table; + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 4), + google__protobuf__DescriptorProto_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 5), + google__protobuf__EnumDescriptorProto_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 6), + google__protobuf__ServiceDescriptorProto_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 7), + google__protobuf__FieldDescriptorProto_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 8), + google__protobuf__FileOptions_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 9), + google__protobuf__SourceCodeInfo_msg_init()); + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 14), + google__protobuf__Edition_enum_init()); + return mini_table; } const upb_MiniTable* google__protobuf__DescriptorProto_msg_init() { @@ -61,16 +93,52 @@ const upb_MiniTable* google__protobuf__DescriptorProto_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 2), google__protobuf__FieldDescriptorProto_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 6), google__protobuf__FieldDescriptorProto_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 3), google__protobuf__DescriptorProto_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 4), google__protobuf__EnumDescriptorProto_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 5), google__protobuf__DescriptorProto__ExtensionRange_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 8), google__protobuf__OneofDescriptorProto_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 7), google__protobuf__MessageOptions_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 9), google__protobuf__DescriptorProto__ReservedRange_msg_init()); - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 11), google__protobuf__SymbolVisibility_enum_init()); - return mini_table; + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 2), + google__protobuf__FieldDescriptorProto_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 6), + google__protobuf__FieldDescriptorProto_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 3), + google__protobuf__DescriptorProto_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 4), + google__protobuf__EnumDescriptorProto_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 5), + google__protobuf__DescriptorProto__ExtensionRange_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 8), + google__protobuf__OneofDescriptorProto_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 7), + google__protobuf__MessageOptions_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 9), + google__protobuf__DescriptorProto__ReservedRange_msg_init()); + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 11), + google__protobuf__SymbolVisibility_enum_init()); + return mini_table; } const upb_MiniTable* google__protobuf__DescriptorProto__ExtensionRange_msg_init() { @@ -86,8 +154,12 @@ const upb_MiniTable* google__protobuf__DescriptorProto__ExtensionRange_msg_init( upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 3), google__protobuf__ExtensionRangeOptions_msg_init()); - return mini_table; + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 3), + google__protobuf__ExtensionRangeOptions_msg_init()); + return mini_table; } const upb_MiniTable* google__protobuf__DescriptorProto__ReservedRange_msg_init() { @@ -103,7 +175,7 @@ const upb_MiniTable* google__protobuf__DescriptorProto__ReservedRange_msg_init() upb_Status_ErrorMessage(&status)); abort(); } - return mini_table; + return mini_table; } const upb_MiniTable* google__protobuf__ExtensionRangeOptions_msg_init() { @@ -119,11 +191,27 @@ const upb_MiniTable* google__protobuf__ExtensionRangeOptions_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 999), google__protobuf__UninterpretedOption_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 2), google__protobuf__ExtensionRangeOptions__Declaration_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 50), google__protobuf__FeatureSet_msg_init()); - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 3), google__protobuf__ExtensionRangeOptions__VerificationState_enum_init()); - return mini_table; + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 999), + google__protobuf__UninterpretedOption_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 2), + google__protobuf__ExtensionRangeOptions__Declaration_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 50), + google__protobuf__FeatureSet_msg_init()); + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 3), + google__protobuf__ExtensionRangeOptions__VerificationState_enum_init()); + return mini_table; } const upb_MiniTable* google__protobuf__ExtensionRangeOptions__Declaration_msg_init() { @@ -139,7 +227,7 @@ const upb_MiniTable* google__protobuf__ExtensionRangeOptions__Declaration_msg_in upb_Status_ErrorMessage(&status)); abort(); } - return mini_table; + return mini_table; } const upb_MiniTable* google__protobuf__FieldDescriptorProto_msg_init() { @@ -155,10 +243,22 @@ const upb_MiniTable* google__protobuf__FieldDescriptorProto_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 4), google__protobuf__FieldDescriptorProto__Label_enum_init()); - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 5), google__protobuf__FieldDescriptorProto__Type_enum_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 8), google__protobuf__FieldOptions_msg_init()); - return mini_table; + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 4), + google__protobuf__FieldDescriptorProto__Label_enum_init()); + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 5), + google__protobuf__FieldDescriptorProto__Type_enum_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 8), + google__protobuf__FieldOptions_msg_init()); + return mini_table; } const upb_MiniTable* google__protobuf__OneofDescriptorProto_msg_init() { @@ -174,8 +274,12 @@ const upb_MiniTable* google__protobuf__OneofDescriptorProto_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 2), google__protobuf__OneofOptions_msg_init()); - return mini_table; + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 2), + google__protobuf__OneofOptions_msg_init()); + return mini_table; } const upb_MiniTable* google__protobuf__EnumDescriptorProto_msg_init() { @@ -191,11 +295,27 @@ const upb_MiniTable* google__protobuf__EnumDescriptorProto_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 2), google__protobuf__EnumValueDescriptorProto_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 3), google__protobuf__EnumOptions_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 4), google__protobuf__EnumDescriptorProto__EnumReservedRange_msg_init()); - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 6), google__protobuf__SymbolVisibility_enum_init()); - return mini_table; + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 2), + google__protobuf__EnumValueDescriptorProto_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 3), + google__protobuf__EnumOptions_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 4), + google__protobuf__EnumDescriptorProto__EnumReservedRange_msg_init()); + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 6), + google__protobuf__SymbolVisibility_enum_init()); + return mini_table; } const upb_MiniTable* google__protobuf__EnumDescriptorProto__EnumReservedRange_msg_init() { @@ -211,7 +331,7 @@ const upb_MiniTable* google__protobuf__EnumDescriptorProto__EnumReservedRange_ms upb_Status_ErrorMessage(&status)); abort(); } - return mini_table; + return mini_table; } const upb_MiniTable* google__protobuf__EnumValueDescriptorProto_msg_init() { @@ -227,8 +347,12 @@ const upb_MiniTable* google__protobuf__EnumValueDescriptorProto_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 3), google__protobuf__EnumValueOptions_msg_init()); - return mini_table; + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 3), + google__protobuf__EnumValueOptions_msg_init()); + return mini_table; } const upb_MiniTable* google__protobuf__ServiceDescriptorProto_msg_init() { @@ -244,9 +368,17 @@ const upb_MiniTable* google__protobuf__ServiceDescriptorProto_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 2), google__protobuf__MethodDescriptorProto_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 3), google__protobuf__ServiceOptions_msg_init()); - return mini_table; + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 2), + google__protobuf__MethodDescriptorProto_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 3), + google__protobuf__ServiceOptions_msg_init()); + return mini_table; } const upb_MiniTable* google__protobuf__MethodDescriptorProto_msg_init() { @@ -262,8 +394,12 @@ const upb_MiniTable* google__protobuf__MethodDescriptorProto_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 4), google__protobuf__MethodOptions_msg_init()); - return mini_table; + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 4), + google__protobuf__MethodOptions_msg_init()); + return mini_table; } const upb_MiniTable* google__protobuf__FileOptions_msg_init() { @@ -279,10 +415,22 @@ const upb_MiniTable* google__protobuf__FileOptions_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 9), google__protobuf__FileOptions__OptimizeMode_enum_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 50), google__protobuf__FeatureSet_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 999), google__protobuf__UninterpretedOption_msg_init()); - return mini_table; + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 9), + google__protobuf__FileOptions__OptimizeMode_enum_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 50), + google__protobuf__FeatureSet_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 999), + google__protobuf__UninterpretedOption_msg_init()); + return mini_table; } const upb_MiniTable* google__protobuf__MessageOptions_msg_init() { @@ -298,9 +446,17 @@ const upb_MiniTable* google__protobuf__MessageOptions_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 12), google__protobuf__FeatureSet_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 999), google__protobuf__UninterpretedOption_msg_init()); - return mini_table; + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 12), + google__protobuf__FeatureSet_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 999), + google__protobuf__UninterpretedOption_msg_init()); + return mini_table; } const upb_MiniTable* google__protobuf__FieldOptions_msg_init() { @@ -316,15 +472,47 @@ const upb_MiniTable* google__protobuf__FieldOptions_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 1), google__protobuf__FieldOptions__CType_enum_init()); - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 6), google__protobuf__FieldOptions__JSType_enum_init()); - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 17), google__protobuf__FieldOptions__OptionRetention_enum_init()); - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 19), google__protobuf__FieldOptions__OptionTargetType_enum_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 20), google__protobuf__FieldOptions__EditionDefault_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 21), google__protobuf__FeatureSet_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 22), google__protobuf__FieldOptions__FeatureSupport_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 999), google__protobuf__UninterpretedOption_msg_init()); - return mini_table; + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 1), + google__protobuf__FieldOptions__CType_enum_init()); + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 6), + google__protobuf__FieldOptions__JSType_enum_init()); + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 17), + google__protobuf__FieldOptions__OptionRetention_enum_init()); + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 19), + google__protobuf__FieldOptions__OptionTargetType_enum_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 20), + google__protobuf__FieldOptions__EditionDefault_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 21), + google__protobuf__FeatureSet_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 22), + google__protobuf__FieldOptions__FeatureSupport_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 999), + google__protobuf__UninterpretedOption_msg_init()); + return mini_table; } const upb_MiniTable* google__protobuf__FieldOptions__EditionDefault_msg_init() { @@ -340,8 +528,12 @@ const upb_MiniTable* google__protobuf__FieldOptions__EditionDefault_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 3), google__protobuf__Edition_enum_init()); - return mini_table; + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 3), + google__protobuf__Edition_enum_init()); + return mini_table; } const upb_MiniTable* google__protobuf__FieldOptions__FeatureSupport_msg_init() { @@ -357,10 +549,22 @@ const upb_MiniTable* google__protobuf__FieldOptions__FeatureSupport_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 1), google__protobuf__Edition_enum_init()); - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 2), google__protobuf__Edition_enum_init()); - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 4), google__protobuf__Edition_enum_init()); - return mini_table; + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 1), + google__protobuf__Edition_enum_init()); + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 2), + google__protobuf__Edition_enum_init()); + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 4), + google__protobuf__Edition_enum_init()); + return mini_table; } const upb_MiniTable* google__protobuf__OneofOptions_msg_init() { @@ -376,9 +580,17 @@ const upb_MiniTable* google__protobuf__OneofOptions_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 1), google__protobuf__FeatureSet_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 999), google__protobuf__UninterpretedOption_msg_init()); - return mini_table; + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 1), + google__protobuf__FeatureSet_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 999), + google__protobuf__UninterpretedOption_msg_init()); + return mini_table; } const upb_MiniTable* google__protobuf__EnumOptions_msg_init() { @@ -394,9 +606,17 @@ const upb_MiniTable* google__protobuf__EnumOptions_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 7), google__protobuf__FeatureSet_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 999), google__protobuf__UninterpretedOption_msg_init()); - return mini_table; + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 7), + google__protobuf__FeatureSet_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 999), + google__protobuf__UninterpretedOption_msg_init()); + return mini_table; } const upb_MiniTable* google__protobuf__EnumValueOptions_msg_init() { @@ -412,10 +632,22 @@ const upb_MiniTable* google__protobuf__EnumValueOptions_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 2), google__protobuf__FeatureSet_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 4), google__protobuf__FieldOptions__FeatureSupport_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 999), google__protobuf__UninterpretedOption_msg_init()); - return mini_table; + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 2), + google__protobuf__FeatureSet_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 4), + google__protobuf__FieldOptions__FeatureSupport_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 999), + google__protobuf__UninterpretedOption_msg_init()); + return mini_table; } const upb_MiniTable* google__protobuf__ServiceOptions_msg_init() { @@ -431,9 +663,17 @@ const upb_MiniTable* google__protobuf__ServiceOptions_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 34), google__protobuf__FeatureSet_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 999), google__protobuf__UninterpretedOption_msg_init()); - return mini_table; + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 34), + google__protobuf__FeatureSet_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 999), + google__protobuf__UninterpretedOption_msg_init()); + return mini_table; } const upb_MiniTable* google__protobuf__MethodOptions_msg_init() { @@ -449,10 +689,22 @@ const upb_MiniTable* google__protobuf__MethodOptions_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 34), google__protobuf__MethodOptions__IdempotencyLevel_enum_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 35), google__protobuf__FeatureSet_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 999), google__protobuf__UninterpretedOption_msg_init()); - return mini_table; + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 34), + google__protobuf__MethodOptions__IdempotencyLevel_enum_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 35), + google__protobuf__FeatureSet_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 999), + google__protobuf__UninterpretedOption_msg_init()); + return mini_table; } const upb_MiniTable* google__protobuf__UninterpretedOption_msg_init() { @@ -468,8 +720,12 @@ const upb_MiniTable* google__protobuf__UninterpretedOption_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 2), google__protobuf__UninterpretedOption__NamePart_msg_init()); - return mini_table; + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 2), + google__protobuf__UninterpretedOption__NamePart_msg_init()); + return mini_table; } const upb_MiniTable* google__protobuf__UninterpretedOption__NamePart_msg_init() { @@ -485,7 +741,7 @@ const upb_MiniTable* google__protobuf__UninterpretedOption__NamePart_msg_init() upb_Status_ErrorMessage(&status)); abort(); } - return mini_table; + return mini_table; } const upb_MiniTable* google__protobuf__FeatureSet_msg_init() { @@ -501,15 +757,47 @@ const upb_MiniTable* google__protobuf__FeatureSet_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 1), google__protobuf__FeatureSet__FieldPresence_enum_init()); - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 2), google__protobuf__FeatureSet__EnumType_enum_init()); - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 3), google__protobuf__FeatureSet__RepeatedFieldEncoding_enum_init()); - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 4), google__protobuf__FeatureSet__Utf8Validation_enum_init()); - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 5), google__protobuf__FeatureSet__MessageEncoding_enum_init()); - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 6), google__protobuf__FeatureSet__JsonFormat_enum_init()); - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 7), google__protobuf__FeatureSet__EnforceNamingStyle_enum_init()); - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 8), google__protobuf__FeatureSet__VisibilityFeature__DefaultSymbolVisibility_enum_init()); - return mini_table; + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 1), + google__protobuf__FeatureSet__FieldPresence_enum_init()); + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 2), + google__protobuf__FeatureSet__EnumType_enum_init()); + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 3), + google__protobuf__FeatureSet__RepeatedFieldEncoding_enum_init()); + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 4), + google__protobuf__FeatureSet__Utf8Validation_enum_init()); + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 5), + google__protobuf__FeatureSet__MessageEncoding_enum_init()); + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 6), + google__protobuf__FeatureSet__JsonFormat_enum_init()); + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 7), + google__protobuf__FeatureSet__EnforceNamingStyle_enum_init()); + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 8), + google__protobuf__FeatureSet__VisibilityFeature__DefaultSymbolVisibility_enum_init()); + return mini_table; } const upb_MiniTable* google__protobuf__FeatureSet__VisibilityFeature_msg_init() { @@ -525,7 +813,7 @@ const upb_MiniTable* google__protobuf__FeatureSet__VisibilityFeature_msg_init() upb_Status_ErrorMessage(&status)); abort(); } - return mini_table; + return mini_table; } const upb_MiniTable* google__protobuf__FeatureSetDefaults_msg_init() { @@ -541,10 +829,22 @@ const upb_MiniTable* google__protobuf__FeatureSetDefaults_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 1), google__protobuf__FeatureSetDefaults__FeatureSetEditionDefault_msg_init()); - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 4), google__protobuf__Edition_enum_init()); - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 5), google__protobuf__Edition_enum_init()); - return mini_table; + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 1), + google__protobuf__FeatureSetDefaults__FeatureSetEditionDefault_msg_init()); + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 4), + google__protobuf__Edition_enum_init()); + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 5), + google__protobuf__Edition_enum_init()); + return mini_table; } const upb_MiniTable* google__protobuf__FeatureSetDefaults__FeatureSetEditionDefault_msg_init() { @@ -560,10 +860,22 @@ const upb_MiniTable* google__protobuf__FeatureSetDefaults__FeatureSetEditionDefa upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 3), google__protobuf__Edition_enum_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 4), google__protobuf__FeatureSet_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 5), google__protobuf__FeatureSet_msg_init()); - return mini_table; + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 3), + google__protobuf__Edition_enum_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 4), + google__protobuf__FeatureSet_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 5), + google__protobuf__FeatureSet_msg_init()); + return mini_table; } const upb_MiniTable* google__protobuf__SourceCodeInfo_msg_init() { @@ -579,8 +891,12 @@ const upb_MiniTable* google__protobuf__SourceCodeInfo_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 1), google__protobuf__SourceCodeInfo__Location_msg_init()); - return mini_table; + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 1), + google__protobuf__SourceCodeInfo__Location_msg_init()); + return mini_table; } const upb_MiniTable* google__protobuf__SourceCodeInfo__Location_msg_init() { @@ -596,7 +912,7 @@ const upb_MiniTable* google__protobuf__SourceCodeInfo__Location_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - return mini_table; + return mini_table; } const upb_MiniTable* google__protobuf__GeneratedCodeInfo_msg_init() { @@ -612,8 +928,12 @@ const upb_MiniTable* google__protobuf__GeneratedCodeInfo_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 1), google__protobuf__GeneratedCodeInfo__Annotation_msg_init()); - return mini_table; + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 1), + google__protobuf__GeneratedCodeInfo__Annotation_msg_init()); + return mini_table; } const upb_MiniTable* google__protobuf__GeneratedCodeInfo__Annotation_msg_init() { @@ -629,17 +949,21 @@ const upb_MiniTable* google__protobuf__GeneratedCodeInfo__Annotation_msg_init() upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubEnum(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 5), google__protobuf__GeneratedCodeInfo__Annotation__Semantic_enum_init()); - return mini_table; + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 5), + google__protobuf__GeneratedCodeInfo__Annotation__Semantic_enum_init()); + return mini_table; } const upb_MiniTableEnum* google__protobuf__Edition_enum_init() { static const upb_MiniTableEnum* mini_table = NULL; static const char* mini_descriptor = "!)~z!|a1qt_b)|i}{~~`!"; if (mini_table) return mini_table; - mini_table = - upb_MiniTableEnum_Build(mini_descriptor, strlen(mini_descriptor), - upb_BootstrapArena(), NULL); + mini_table = upb_MiniTableEnum_Build(mini_descriptor, + strlen(mini_descriptor), + upb_BootstrapArena(), NULL); return mini_table; } @@ -647,9 +971,9 @@ const upb_MiniTableEnum* google__protobuf__ExtensionRangeOptions__VerificationSt static const upb_MiniTableEnum* mini_table = NULL; static const char* mini_descriptor = "!$"; if (mini_table) return mini_table; - mini_table = - upb_MiniTableEnum_Build(mini_descriptor, strlen(mini_descriptor), - upb_BootstrapArena(), NULL); + mini_table = upb_MiniTableEnum_Build(mini_descriptor, + strlen(mini_descriptor), + upb_BootstrapArena(), NULL); return mini_table; } @@ -657,9 +981,9 @@ const upb_MiniTableEnum* google__protobuf__FeatureSet__EnforceNamingStyle_enum_i static const upb_MiniTableEnum* mini_table = NULL; static const char* mini_descriptor = "!)"; if (mini_table) return mini_table; - mini_table = - upb_MiniTableEnum_Build(mini_descriptor, strlen(mini_descriptor), - upb_BootstrapArena(), NULL); + mini_table = upb_MiniTableEnum_Build(mini_descriptor, + strlen(mini_descriptor), + upb_BootstrapArena(), NULL); return mini_table; } @@ -667,9 +991,9 @@ const upb_MiniTableEnum* google__protobuf__FeatureSet__EnumType_enum_init() { static const upb_MiniTableEnum* mini_table = NULL; static const char* mini_descriptor = "!)"; if (mini_table) return mini_table; - mini_table = - upb_MiniTableEnum_Build(mini_descriptor, strlen(mini_descriptor), - upb_BootstrapArena(), NULL); + mini_table = upb_MiniTableEnum_Build(mini_descriptor, + strlen(mini_descriptor), + upb_BootstrapArena(), NULL); return mini_table; } @@ -677,9 +1001,9 @@ const upb_MiniTableEnum* google__protobuf__FeatureSet__FieldPresence_enum_init() static const upb_MiniTableEnum* mini_table = NULL; static const char* mini_descriptor = "!1"; if (mini_table) return mini_table; - mini_table = - upb_MiniTableEnum_Build(mini_descriptor, strlen(mini_descriptor), - upb_BootstrapArena(), NULL); + mini_table = upb_MiniTableEnum_Build(mini_descriptor, + strlen(mini_descriptor), + upb_BootstrapArena(), NULL); return mini_table; } @@ -687,9 +1011,9 @@ const upb_MiniTableEnum* google__protobuf__FeatureSet__JsonFormat_enum_init() { static const upb_MiniTableEnum* mini_table = NULL; static const char* mini_descriptor = "!)"; if (mini_table) return mini_table; - mini_table = - upb_MiniTableEnum_Build(mini_descriptor, strlen(mini_descriptor), - upb_BootstrapArena(), NULL); + mini_table = upb_MiniTableEnum_Build(mini_descriptor, + strlen(mini_descriptor), + upb_BootstrapArena(), NULL); return mini_table; } @@ -697,9 +1021,9 @@ const upb_MiniTableEnum* google__protobuf__FeatureSet__MessageEncoding_enum_init static const upb_MiniTableEnum* mini_table = NULL; static const char* mini_descriptor = "!)"; if (mini_table) return mini_table; - mini_table = - upb_MiniTableEnum_Build(mini_descriptor, strlen(mini_descriptor), - upb_BootstrapArena(), NULL); + mini_table = upb_MiniTableEnum_Build(mini_descriptor, + strlen(mini_descriptor), + upb_BootstrapArena(), NULL); return mini_table; } @@ -707,9 +1031,9 @@ const upb_MiniTableEnum* google__protobuf__FeatureSet__RepeatedFieldEncoding_enu static const upb_MiniTableEnum* mini_table = NULL; static const char* mini_descriptor = "!)"; if (mini_table) return mini_table; - mini_table = - upb_MiniTableEnum_Build(mini_descriptor, strlen(mini_descriptor), - upb_BootstrapArena(), NULL); + mini_table = upb_MiniTableEnum_Build(mini_descriptor, + strlen(mini_descriptor), + upb_BootstrapArena(), NULL); return mini_table; } @@ -717,9 +1041,9 @@ const upb_MiniTableEnum* google__protobuf__FeatureSet__Utf8Validation_enum_init( static const upb_MiniTableEnum* mini_table = NULL; static const char* mini_descriptor = "!/"; if (mini_table) return mini_table; - mini_table = - upb_MiniTableEnum_Build(mini_descriptor, strlen(mini_descriptor), - upb_BootstrapArena(), NULL); + mini_table = upb_MiniTableEnum_Build(mini_descriptor, + strlen(mini_descriptor), + upb_BootstrapArena(), NULL); return mini_table; } @@ -727,9 +1051,9 @@ const upb_MiniTableEnum* google__protobuf__FeatureSet__VisibilityFeature__Defaul static const upb_MiniTableEnum* mini_table = NULL; static const char* mini_descriptor = "!A"; if (mini_table) return mini_table; - mini_table = - upb_MiniTableEnum_Build(mini_descriptor, strlen(mini_descriptor), - upb_BootstrapArena(), NULL); + mini_table = upb_MiniTableEnum_Build(mini_descriptor, + strlen(mini_descriptor), + upb_BootstrapArena(), NULL); return mini_table; } @@ -737,9 +1061,9 @@ const upb_MiniTableEnum* google__protobuf__FieldDescriptorProto__Label_enum_init static const upb_MiniTableEnum* mini_table = NULL; static const char* mini_descriptor = "!0"; if (mini_table) return mini_table; - mini_table = - upb_MiniTableEnum_Build(mini_descriptor, strlen(mini_descriptor), - upb_BootstrapArena(), NULL); + mini_table = upb_MiniTableEnum_Build(mini_descriptor, + strlen(mini_descriptor), + upb_BootstrapArena(), NULL); return mini_table; } @@ -747,9 +1071,9 @@ const upb_MiniTableEnum* google__protobuf__FieldDescriptorProto__Type_enum_init( static const upb_MiniTableEnum* mini_table = NULL; static const char* mini_descriptor = "!@AA1"; if (mini_table) return mini_table; - mini_table = - upb_MiniTableEnum_Build(mini_descriptor, strlen(mini_descriptor), - upb_BootstrapArena(), NULL); + mini_table = upb_MiniTableEnum_Build(mini_descriptor, + strlen(mini_descriptor), + upb_BootstrapArena(), NULL); return mini_table; } @@ -757,9 +1081,9 @@ const upb_MiniTableEnum* google__protobuf__FieldOptions__CType_enum_init() { static const upb_MiniTableEnum* mini_table = NULL; static const char* mini_descriptor = "!)"; if (mini_table) return mini_table; - mini_table = - upb_MiniTableEnum_Build(mini_descriptor, strlen(mini_descriptor), - upb_BootstrapArena(), NULL); + mini_table = upb_MiniTableEnum_Build(mini_descriptor, + strlen(mini_descriptor), + upb_BootstrapArena(), NULL); return mini_table; } @@ -767,9 +1091,9 @@ const upb_MiniTableEnum* google__protobuf__FieldOptions__JSType_enum_init() { static const upb_MiniTableEnum* mini_table = NULL; static const char* mini_descriptor = "!)"; if (mini_table) return mini_table; - mini_table = - upb_MiniTableEnum_Build(mini_descriptor, strlen(mini_descriptor), - upb_BootstrapArena(), NULL); + mini_table = upb_MiniTableEnum_Build(mini_descriptor, + strlen(mini_descriptor), + upb_BootstrapArena(), NULL); return mini_table; } @@ -777,9 +1101,9 @@ const upb_MiniTableEnum* google__protobuf__FieldOptions__OptionRetention_enum_in static const upb_MiniTableEnum* mini_table = NULL; static const char* mini_descriptor = "!)"; if (mini_table) return mini_table; - mini_table = - upb_MiniTableEnum_Build(mini_descriptor, strlen(mini_descriptor), - upb_BootstrapArena(), NULL); + mini_table = upb_MiniTableEnum_Build(mini_descriptor, + strlen(mini_descriptor), + upb_BootstrapArena(), NULL); return mini_table; } @@ -787,9 +1111,9 @@ const upb_MiniTableEnum* google__protobuf__FieldOptions__OptionTargetType_enum_i static const upb_MiniTableEnum* mini_table = NULL; static const char* mini_descriptor = "!AA"; if (mini_table) return mini_table; - mini_table = - upb_MiniTableEnum_Build(mini_descriptor, strlen(mini_descriptor), - upb_BootstrapArena(), NULL); + mini_table = upb_MiniTableEnum_Build(mini_descriptor, + strlen(mini_descriptor), + upb_BootstrapArena(), NULL); return mini_table; } @@ -797,9 +1121,9 @@ const upb_MiniTableEnum* google__protobuf__FileOptions__OptimizeMode_enum_init() static const upb_MiniTableEnum* mini_table = NULL; static const char* mini_descriptor = "!0"; if (mini_table) return mini_table; - mini_table = - upb_MiniTableEnum_Build(mini_descriptor, strlen(mini_descriptor), - upb_BootstrapArena(), NULL); + mini_table = upb_MiniTableEnum_Build(mini_descriptor, + strlen(mini_descriptor), + upb_BootstrapArena(), NULL); return mini_table; } @@ -807,9 +1131,9 @@ const upb_MiniTableEnum* google__protobuf__GeneratedCodeInfo__Annotation__Semant static const upb_MiniTableEnum* mini_table = NULL; static const char* mini_descriptor = "!)"; if (mini_table) return mini_table; - mini_table = - upb_MiniTableEnum_Build(mini_descriptor, strlen(mini_descriptor), - upb_BootstrapArena(), NULL); + mini_table = upb_MiniTableEnum_Build(mini_descriptor, + strlen(mini_descriptor), + upb_BootstrapArena(), NULL); return mini_table; } @@ -817,9 +1141,9 @@ const upb_MiniTableEnum* google__protobuf__MethodOptions__IdempotencyLevel_enum_ static const upb_MiniTableEnum* mini_table = NULL; static const char* mini_descriptor = "!)"; if (mini_table) return mini_table; - mini_table = - upb_MiniTableEnum_Build(mini_descriptor, strlen(mini_descriptor), - upb_BootstrapArena(), NULL); + mini_table = upb_MiniTableEnum_Build(mini_descriptor, + strlen(mini_descriptor), + upb_BootstrapArena(), NULL); return mini_table; } @@ -827,9 +1151,9 @@ const upb_MiniTableEnum* google__protobuf__SymbolVisibility_enum_init() { static const upb_MiniTableEnum* mini_table = NULL; static const char* mini_descriptor = "!)"; if (mini_table) return mini_table; - mini_table = - upb_MiniTableEnum_Build(mini_descriptor, strlen(mini_descriptor), - upb_BootstrapArena(), NULL); + mini_table = upb_MiniTableEnum_Build(mini_descriptor, + strlen(mini_descriptor), + upb_BootstrapArena(), NULL); return mini_table; } diff --git a/upb/reflection/stage0/google/protobuf/descriptor.upb.h b/upb/reflection/stage0/google/protobuf/descriptor.upb.h index 12f3fdf93601c..b244126f5efef 100644 --- a/upb/reflection/stage0/google/protobuf/descriptor.upb.h +++ b/upb/reflection/stage0/google/protobuf/descriptor.upb.h @@ -10,14 +10,12 @@ #define GOOGLE_PROTOBUF_DESCRIPTOR_PROTO_UPB_H__UPB_H_ #include "upb/generated_code_support.h" - // Must be last. #include "upb/port/def.inc" #ifdef __cplusplus extern "C" { #endif - extern const upb_MiniTable* google__protobuf__FileDescriptorSet_msg_init(void); extern const upb_MiniTable* google__protobuf__FileDescriptorProto_msg_init(void); extern const upb_MiniTable* google__protobuf__DescriptorProto_msg_init(void); @@ -73,40 +71,142 @@ extern const upb_MiniTableEnum* google__protobuf__GeneratedCodeInfo__Annotation_ extern const upb_MiniTableEnum* google__protobuf__MethodOptions__IdempotencyLevel_enum_init(void); extern const upb_MiniTableEnum* google__protobuf__SymbolVisibility_enum_init(void); -typedef struct google_protobuf_FileDescriptorSet { upb_Message UPB_PRIVATE(base); } google_protobuf_FileDescriptorSet; -typedef struct google_protobuf_FileDescriptorProto { upb_Message UPB_PRIVATE(base); } google_protobuf_FileDescriptorProto; -typedef struct google_protobuf_DescriptorProto { upb_Message UPB_PRIVATE(base); } google_protobuf_DescriptorProto; -typedef struct google_protobuf_DescriptorProto_ExtensionRange { upb_Message UPB_PRIVATE(base); } google_protobuf_DescriptorProto_ExtensionRange; -typedef struct google_protobuf_DescriptorProto_ReservedRange { upb_Message UPB_PRIVATE(base); } google_protobuf_DescriptorProto_ReservedRange; -typedef struct google_protobuf_ExtensionRangeOptions { upb_Message UPB_PRIVATE(base); } google_protobuf_ExtensionRangeOptions; -typedef struct google_protobuf_ExtensionRangeOptions_Declaration { upb_Message UPB_PRIVATE(base); } google_protobuf_ExtensionRangeOptions_Declaration; -typedef struct google_protobuf_FieldDescriptorProto { upb_Message UPB_PRIVATE(base); } google_protobuf_FieldDescriptorProto; -typedef struct google_protobuf_OneofDescriptorProto { upb_Message UPB_PRIVATE(base); } google_protobuf_OneofDescriptorProto; -typedef struct google_protobuf_EnumDescriptorProto { upb_Message UPB_PRIVATE(base); } google_protobuf_EnumDescriptorProto; -typedef struct google_protobuf_EnumDescriptorProto_EnumReservedRange { upb_Message UPB_PRIVATE(base); } google_protobuf_EnumDescriptorProto_EnumReservedRange; -typedef struct google_protobuf_EnumValueDescriptorProto { upb_Message UPB_PRIVATE(base); } google_protobuf_EnumValueDescriptorProto; -typedef struct google_protobuf_ServiceDescriptorProto { upb_Message UPB_PRIVATE(base); } google_protobuf_ServiceDescriptorProto; -typedef struct google_protobuf_MethodDescriptorProto { upb_Message UPB_PRIVATE(base); } google_protobuf_MethodDescriptorProto; -typedef struct google_protobuf_FileOptions { upb_Message UPB_PRIVATE(base); } google_protobuf_FileOptions; -typedef struct google_protobuf_MessageOptions { upb_Message UPB_PRIVATE(base); } google_protobuf_MessageOptions; -typedef struct google_protobuf_FieldOptions { upb_Message UPB_PRIVATE(base); } google_protobuf_FieldOptions; -typedef struct google_protobuf_FieldOptions_EditionDefault { upb_Message UPB_PRIVATE(base); } google_protobuf_FieldOptions_EditionDefault; -typedef struct google_protobuf_FieldOptions_FeatureSupport { upb_Message UPB_PRIVATE(base); } google_protobuf_FieldOptions_FeatureSupport; -typedef struct google_protobuf_OneofOptions { upb_Message UPB_PRIVATE(base); } google_protobuf_OneofOptions; -typedef struct google_protobuf_EnumOptions { upb_Message UPB_PRIVATE(base); } google_protobuf_EnumOptions; -typedef struct google_protobuf_EnumValueOptions { upb_Message UPB_PRIVATE(base); } google_protobuf_EnumValueOptions; -typedef struct google_protobuf_ServiceOptions { upb_Message UPB_PRIVATE(base); } google_protobuf_ServiceOptions; -typedef struct google_protobuf_MethodOptions { upb_Message UPB_PRIVATE(base); } google_protobuf_MethodOptions; -typedef struct google_protobuf_UninterpretedOption { upb_Message UPB_PRIVATE(base); } google_protobuf_UninterpretedOption; -typedef struct google_protobuf_UninterpretedOption_NamePart { upb_Message UPB_PRIVATE(base); } google_protobuf_UninterpretedOption_NamePart; -typedef struct google_protobuf_FeatureSet { upb_Message UPB_PRIVATE(base); } google_protobuf_FeatureSet; -typedef struct google_protobuf_FeatureSet_VisibilityFeature { upb_Message UPB_PRIVATE(base); } google_protobuf_FeatureSet_VisibilityFeature; -typedef struct google_protobuf_FeatureSetDefaults { upb_Message UPB_PRIVATE(base); } google_protobuf_FeatureSetDefaults; -typedef struct google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault { upb_Message UPB_PRIVATE(base); } google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault; -typedef struct google_protobuf_SourceCodeInfo { upb_Message UPB_PRIVATE(base); } google_protobuf_SourceCodeInfo; -typedef struct google_protobuf_SourceCodeInfo_Location { upb_Message UPB_PRIVATE(base); } google_protobuf_SourceCodeInfo_Location; -typedef struct google_protobuf_GeneratedCodeInfo { upb_Message UPB_PRIVATE(base); } google_protobuf_GeneratedCodeInfo; -typedef struct google_protobuf_GeneratedCodeInfo_Annotation { upb_Message UPB_PRIVATE(base); } google_protobuf_GeneratedCodeInfo_Annotation; +typedef struct google_protobuf_FileDescriptorSet { + upb_Message UPB_PRIVATE(base); +} google_protobuf_FileDescriptorSet; + +typedef struct google_protobuf_FileDescriptorProto { + upb_Message UPB_PRIVATE(base); +} google_protobuf_FileDescriptorProto; + +typedef struct google_protobuf_DescriptorProto { + upb_Message UPB_PRIVATE(base); +} google_protobuf_DescriptorProto; + +typedef struct google_protobuf_DescriptorProto_ExtensionRange { + upb_Message UPB_PRIVATE(base); +} google_protobuf_DescriptorProto_ExtensionRange; + +typedef struct google_protobuf_DescriptorProto_ReservedRange { + upb_Message UPB_PRIVATE(base); +} google_protobuf_DescriptorProto_ReservedRange; + +typedef struct google_protobuf_ExtensionRangeOptions { + upb_Message UPB_PRIVATE(base); +} google_protobuf_ExtensionRangeOptions; + +typedef struct google_protobuf_ExtensionRangeOptions_Declaration { + upb_Message UPB_PRIVATE(base); +} google_protobuf_ExtensionRangeOptions_Declaration; + +typedef struct google_protobuf_FieldDescriptorProto { + upb_Message UPB_PRIVATE(base); +} google_protobuf_FieldDescriptorProto; + +typedef struct google_protobuf_OneofDescriptorProto { + upb_Message UPB_PRIVATE(base); +} google_protobuf_OneofDescriptorProto; + +typedef struct google_protobuf_EnumDescriptorProto { + upb_Message UPB_PRIVATE(base); +} google_protobuf_EnumDescriptorProto; + +typedef struct google_protobuf_EnumDescriptorProto_EnumReservedRange { + upb_Message UPB_PRIVATE(base); +} google_protobuf_EnumDescriptorProto_EnumReservedRange; + +typedef struct google_protobuf_EnumValueDescriptorProto { + upb_Message UPB_PRIVATE(base); +} google_protobuf_EnumValueDescriptorProto; + +typedef struct google_protobuf_ServiceDescriptorProto { + upb_Message UPB_PRIVATE(base); +} google_protobuf_ServiceDescriptorProto; + +typedef struct google_protobuf_MethodDescriptorProto { + upb_Message UPB_PRIVATE(base); +} google_protobuf_MethodDescriptorProto; + +typedef struct google_protobuf_FileOptions { + upb_Message UPB_PRIVATE(base); +} google_protobuf_FileOptions; + +typedef struct google_protobuf_MessageOptions { + upb_Message UPB_PRIVATE(base); +} google_protobuf_MessageOptions; + +typedef struct google_protobuf_FieldOptions { + upb_Message UPB_PRIVATE(base); +} google_protobuf_FieldOptions; + +typedef struct google_protobuf_FieldOptions_EditionDefault { + upb_Message UPB_PRIVATE(base); +} google_protobuf_FieldOptions_EditionDefault; + +typedef struct google_protobuf_FieldOptions_FeatureSupport { + upb_Message UPB_PRIVATE(base); +} google_protobuf_FieldOptions_FeatureSupport; + +typedef struct google_protobuf_OneofOptions { + upb_Message UPB_PRIVATE(base); +} google_protobuf_OneofOptions; + +typedef struct google_protobuf_EnumOptions { + upb_Message UPB_PRIVATE(base); +} google_protobuf_EnumOptions; + +typedef struct google_protobuf_EnumValueOptions { + upb_Message UPB_PRIVATE(base); +} google_protobuf_EnumValueOptions; + +typedef struct google_protobuf_ServiceOptions { + upb_Message UPB_PRIVATE(base); +} google_protobuf_ServiceOptions; + +typedef struct google_protobuf_MethodOptions { + upb_Message UPB_PRIVATE(base); +} google_protobuf_MethodOptions; + +typedef struct google_protobuf_UninterpretedOption { + upb_Message UPB_PRIVATE(base); +} google_protobuf_UninterpretedOption; + +typedef struct google_protobuf_UninterpretedOption_NamePart { + upb_Message UPB_PRIVATE(base); +} google_protobuf_UninterpretedOption_NamePart; + +typedef struct google_protobuf_FeatureSet { + upb_Message UPB_PRIVATE(base); +} google_protobuf_FeatureSet; + +typedef struct google_protobuf_FeatureSet_VisibilityFeature { + upb_Message UPB_PRIVATE(base); +} google_protobuf_FeatureSet_VisibilityFeature; + +typedef struct google_protobuf_FeatureSetDefaults { + upb_Message UPB_PRIVATE(base); +} google_protobuf_FeatureSetDefaults; + +typedef struct google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault { + upb_Message UPB_PRIVATE(base); +} google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault; + +typedef struct google_protobuf_SourceCodeInfo { + upb_Message UPB_PRIVATE(base); +} google_protobuf_SourceCodeInfo; + +typedef struct google_protobuf_SourceCodeInfo_Location { + upb_Message UPB_PRIVATE(base); +} google_protobuf_SourceCodeInfo_Location; + +typedef struct google_protobuf_GeneratedCodeInfo { + upb_Message UPB_PRIVATE(base); +} google_protobuf_GeneratedCodeInfo; + +typedef struct google_protobuf_GeneratedCodeInfo_Annotation { + upb_Message UPB_PRIVATE(base); +} google_protobuf_GeneratedCodeInfo_Annotation; + typedef enum { google_protobuf_EDITION_UNKNOWN = 0, @@ -264,37 +364,39 @@ typedef enum { /* google.protobuf.FileDescriptorSet */ - UPB_INLINE google_protobuf_FileDescriptorSet* google_protobuf_FileDescriptorSet_new(upb_Arena* arena) { return (google_protobuf_FileDescriptorSet*)_upb_Message_New(google__protobuf__FileDescriptorSet_msg_init(), arena); } -UPB_INLINE google_protobuf_FileDescriptorSet* google_protobuf_FileDescriptorSet_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_FileDescriptorSet* google_protobuf_FileDescriptorSet_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_FileDescriptorSet* ret = google_protobuf_FileDescriptorSet_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FileDescriptorSet_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FileDescriptorSet_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_FileDescriptorSet* google_protobuf_FileDescriptorSet_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_FileDescriptorSet* google_protobuf_FileDescriptorSet_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_FileDescriptorSet* ret = google_protobuf_FileDescriptorSet_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FileDescriptorSet_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FileDescriptorSet_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_FileDescriptorSet_serialize(const google_protobuf_FileDescriptorSet* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_FileDescriptorSet_serialize(const google_protobuf_FileDescriptorSet* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__FileDescriptorSet_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_FileDescriptorSet_serialize_ex(const google_protobuf_FileDescriptorSet* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_FileDescriptorSet_serialize_ex(const google_protobuf_FileDescriptorSet* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__FileDescriptorSet_msg_init(), options, arena, &ptr, len); return ptr; @@ -303,7 +405,8 @@ UPB_INLINE void google_protobuf_FileDescriptorSet_clear_file(google_protobuf_Fil const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorSet_msg_init(), 1); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_FileDescriptorProto* const* google_protobuf_FileDescriptorSet_file(const google_protobuf_FileDescriptorSet* msg, size_t* size) { +UPB_INLINE const google_protobuf_FileDescriptorProto* const* google_protobuf_FileDescriptorSet_file(const google_protobuf_FileDescriptorSet* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorSet_msg_init(), 1); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -314,7 +417,10 @@ UPB_INLINE const google_protobuf_FileDescriptorProto* const* google_protobuf_Fil return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorSet_file_upb_array(const google_protobuf_FileDescriptorSet* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorSet_file_upb_array( + const google_protobuf_FileDescriptorSet* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorSet_msg_init(), 1); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -322,7 +428,9 @@ UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorSet_file_upb_array(co } return arr; } -UPB_INLINE upb_Array* _google_protobuf_FileDescriptorSet_file_mutable_upb_array(google_protobuf_FileDescriptorSet* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_FileDescriptorSet_file_mutable_upb_array( + google_protobuf_FileDescriptorSet* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorSet_msg_init(), 1); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -332,7 +440,8 @@ UPB_INLINE upb_Array* _google_protobuf_FileDescriptorSet_file_mutable_upb_array( return arr; } -UPB_INLINE google_protobuf_FileDescriptorProto** google_protobuf_FileDescriptorSet_mutable_file(google_protobuf_FileDescriptorSet* msg, size_t* size) { +UPB_INLINE google_protobuf_FileDescriptorProto** google_protobuf_FileDescriptorSet_mutable_file(google_protobuf_FileDescriptorSet* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorSet_msg_init(), 1); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -343,12 +452,16 @@ UPB_INLINE google_protobuf_FileDescriptorProto** google_protobuf_FileDescriptorS return NULL; } } -UPB_INLINE google_protobuf_FileDescriptorProto** google_protobuf_FileDescriptorSet_resize_file(google_protobuf_FileDescriptorSet* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_FileDescriptorProto** google_protobuf_FileDescriptorSet_resize_file(google_protobuf_FileDescriptorSet* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorSet_msg_init(), 1); - return (google_protobuf_FileDescriptorProto**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_FileDescriptorProto**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_FileDescriptorProto* google_protobuf_FileDescriptorSet_add_file(google_protobuf_FileDescriptorSet* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_FileDescriptorProto* google_protobuf_FileDescriptorSet_add_file( + google_protobuf_FileDescriptorSet* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorSet_msg_init(), 1); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -356,7 +469,8 @@ UPB_INLINE struct google_protobuf_FileDescriptorProto* google_protobuf_FileDescr arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_FileDescriptorProto* sub = (struct google_protobuf_FileDescriptorProto*)_upb_Message_New(google__protobuf__FileDescriptorProto_msg_init(), arena); + struct google_protobuf_FileDescriptorProto* sub = + (struct google_protobuf_FileDescriptorProto*)_upb_Message_New(google__protobuf__FileDescriptorProto_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); @@ -364,37 +478,39 @@ UPB_INLINE struct google_protobuf_FileDescriptorProto* google_protobuf_FileDescr } /* google.protobuf.FileDescriptorProto */ - UPB_INLINE google_protobuf_FileDescriptorProto* google_protobuf_FileDescriptorProto_new(upb_Arena* arena) { return (google_protobuf_FileDescriptorProto*)_upb_Message_New(google__protobuf__FileDescriptorProto_msg_init(), arena); } -UPB_INLINE google_protobuf_FileDescriptorProto* google_protobuf_FileDescriptorProto_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_FileDescriptorProto* google_protobuf_FileDescriptorProto_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_FileDescriptorProto* ret = google_protobuf_FileDescriptorProto_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FileDescriptorProto_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FileDescriptorProto_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_FileDescriptorProto* google_protobuf_FileDescriptorProto_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_FileDescriptorProto* google_protobuf_FileDescriptorProto_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_FileDescriptorProto* ret = google_protobuf_FileDescriptorProto_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FileDescriptorProto_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FileDescriptorProto_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_FileDescriptorProto_serialize(const google_protobuf_FileDescriptorProto* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_FileDescriptorProto_serialize(const google_protobuf_FileDescriptorProto* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__FileDescriptorProto_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_FileDescriptorProto_serialize_ex(const google_protobuf_FileDescriptorProto* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_FileDescriptorProto_serialize_ex(const google_protobuf_FileDescriptorProto* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__FileDescriptorProto_msg_init(), options, arena, &ptr, len); return ptr; @@ -435,7 +551,8 @@ UPB_INLINE void google_protobuf_FileDescriptorProto_clear_dependency(google_prot const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 3); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE upb_StringView const* google_protobuf_FileDescriptorProto_dependency(const google_protobuf_FileDescriptorProto* msg, size_t* size) { +UPB_INLINE upb_StringView const* google_protobuf_FileDescriptorProto_dependency(const google_protobuf_FileDescriptorProto* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 3); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -446,7 +563,10 @@ UPB_INLINE upb_StringView const* google_protobuf_FileDescriptorProto_dependency( return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorProto_dependency_upb_array(const google_protobuf_FileDescriptorProto* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorProto_dependency_upb_array( + const google_protobuf_FileDescriptorProto* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 3); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -454,7 +574,9 @@ UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorProto_dependency_upb_ } return arr; } -UPB_INLINE upb_Array* _google_protobuf_FileDescriptorProto_dependency_mutable_upb_array(google_protobuf_FileDescriptorProto* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_FileDescriptorProto_dependency_mutable_upb_array( + google_protobuf_FileDescriptorProto* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 3); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -467,7 +589,8 @@ UPB_INLINE void google_protobuf_FileDescriptorProto_clear_message_type(google_pr const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 4); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_DescriptorProto* const* google_protobuf_FileDescriptorProto_message_type(const google_protobuf_FileDescriptorProto* msg, size_t* size) { +UPB_INLINE const google_protobuf_DescriptorProto* const* google_protobuf_FileDescriptorProto_message_type(const google_protobuf_FileDescriptorProto* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 4); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -478,7 +601,10 @@ UPB_INLINE const google_protobuf_DescriptorProto* const* google_protobuf_FileDes return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorProto_message_type_upb_array(const google_protobuf_FileDescriptorProto* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorProto_message_type_upb_array( + const google_protobuf_FileDescriptorProto* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 4); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -486,7 +612,9 @@ UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorProto_message_type_up } return arr; } -UPB_INLINE upb_Array* _google_protobuf_FileDescriptorProto_message_type_mutable_upb_array(google_protobuf_FileDescriptorProto* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_FileDescriptorProto_message_type_mutable_upb_array( + google_protobuf_FileDescriptorProto* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 4); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -499,7 +627,8 @@ UPB_INLINE void google_protobuf_FileDescriptorProto_clear_enum_type(google_proto const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 5); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_EnumDescriptorProto* const* google_protobuf_FileDescriptorProto_enum_type(const google_protobuf_FileDescriptorProto* msg, size_t* size) { +UPB_INLINE const google_protobuf_EnumDescriptorProto* const* google_protobuf_FileDescriptorProto_enum_type(const google_protobuf_FileDescriptorProto* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 5); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -510,7 +639,10 @@ UPB_INLINE const google_protobuf_EnumDescriptorProto* const* google_protobuf_Fil return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorProto_enum_type_upb_array(const google_protobuf_FileDescriptorProto* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorProto_enum_type_upb_array( + const google_protobuf_FileDescriptorProto* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 5); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -518,7 +650,9 @@ UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorProto_enum_type_upb_a } return arr; } -UPB_INLINE upb_Array* _google_protobuf_FileDescriptorProto_enum_type_mutable_upb_array(google_protobuf_FileDescriptorProto* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_FileDescriptorProto_enum_type_mutable_upb_array( + google_protobuf_FileDescriptorProto* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 5); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -531,7 +665,8 @@ UPB_INLINE void google_protobuf_FileDescriptorProto_clear_service(google_protobu const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 6); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_ServiceDescriptorProto* const* google_protobuf_FileDescriptorProto_service(const google_protobuf_FileDescriptorProto* msg, size_t* size) { +UPB_INLINE const google_protobuf_ServiceDescriptorProto* const* google_protobuf_FileDescriptorProto_service(const google_protobuf_FileDescriptorProto* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 6); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -542,7 +677,10 @@ UPB_INLINE const google_protobuf_ServiceDescriptorProto* const* google_protobuf_ return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorProto_service_upb_array(const google_protobuf_FileDescriptorProto* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorProto_service_upb_array( + const google_protobuf_FileDescriptorProto* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 6); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -550,7 +688,9 @@ UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorProto_service_upb_arr } return arr; } -UPB_INLINE upb_Array* _google_protobuf_FileDescriptorProto_service_mutable_upb_array(google_protobuf_FileDescriptorProto* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_FileDescriptorProto_service_mutable_upb_array( + google_protobuf_FileDescriptorProto* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 6); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -563,7 +703,8 @@ UPB_INLINE void google_protobuf_FileDescriptorProto_clear_extension(google_proto const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 7); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_FieldDescriptorProto* const* google_protobuf_FileDescriptorProto_extension(const google_protobuf_FileDescriptorProto* msg, size_t* size) { +UPB_INLINE const google_protobuf_FieldDescriptorProto* const* google_protobuf_FileDescriptorProto_extension(const google_protobuf_FileDescriptorProto* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 7); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -574,7 +715,10 @@ UPB_INLINE const google_protobuf_FieldDescriptorProto* const* google_protobuf_Fi return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorProto_extension_upb_array(const google_protobuf_FileDescriptorProto* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorProto_extension_upb_array( + const google_protobuf_FileDescriptorProto* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 7); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -582,7 +726,9 @@ UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorProto_extension_upb_a } return arr; } -UPB_INLINE upb_Array* _google_protobuf_FileDescriptorProto_extension_mutable_upb_array(google_protobuf_FileDescriptorProto* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_FileDescriptorProto_extension_mutable_upb_array( + google_protobuf_FileDescriptorProto* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 7); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -627,7 +773,8 @@ UPB_INLINE void google_protobuf_FileDescriptorProto_clear_public_dependency(goog const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 10); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE int32_t const* google_protobuf_FileDescriptorProto_public_dependency(const google_protobuf_FileDescriptorProto* msg, size_t* size) { +UPB_INLINE int32_t const* google_protobuf_FileDescriptorProto_public_dependency(const google_protobuf_FileDescriptorProto* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 10); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -638,7 +785,10 @@ UPB_INLINE int32_t const* google_protobuf_FileDescriptorProto_public_dependency( return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorProto_public_dependency_upb_array(const google_protobuf_FileDescriptorProto* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorProto_public_dependency_upb_array( + const google_protobuf_FileDescriptorProto* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 10); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -646,7 +796,9 @@ UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorProto_public_dependen } return arr; } -UPB_INLINE upb_Array* _google_protobuf_FileDescriptorProto_public_dependency_mutable_upb_array(google_protobuf_FileDescriptorProto* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_FileDescriptorProto_public_dependency_mutable_upb_array( + google_protobuf_FileDescriptorProto* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 10); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -659,7 +811,8 @@ UPB_INLINE void google_protobuf_FileDescriptorProto_clear_weak_dependency(google const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 11); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE int32_t const* google_protobuf_FileDescriptorProto_weak_dependency(const google_protobuf_FileDescriptorProto* msg, size_t* size) { +UPB_INLINE int32_t const* google_protobuf_FileDescriptorProto_weak_dependency(const google_protobuf_FileDescriptorProto* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 11); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -670,7 +823,10 @@ UPB_INLINE int32_t const* google_protobuf_FileDescriptorProto_weak_dependency(co return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorProto_weak_dependency_upb_array(const google_protobuf_FileDescriptorProto* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorProto_weak_dependency_upb_array( + const google_protobuf_FileDescriptorProto* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 11); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -678,7 +834,9 @@ UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorProto_weak_dependency } return arr; } -UPB_INLINE upb_Array* _google_protobuf_FileDescriptorProto_weak_dependency_mutable_upb_array(google_protobuf_FileDescriptorProto* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_FileDescriptorProto_weak_dependency_mutable_upb_array( + google_protobuf_FileDescriptorProto* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 11); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -723,7 +881,8 @@ UPB_INLINE void google_protobuf_FileDescriptorProto_clear_option_dependency(goog const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 15); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE upb_StringView const* google_protobuf_FileDescriptorProto_option_dependency(const google_protobuf_FileDescriptorProto* msg, size_t* size) { +UPB_INLINE upb_StringView const* google_protobuf_FileDescriptorProto_option_dependency(const google_protobuf_FileDescriptorProto* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 15); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -734,7 +893,10 @@ UPB_INLINE upb_StringView const* google_protobuf_FileDescriptorProto_option_depe return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorProto_option_dependency_upb_array(const google_protobuf_FileDescriptorProto* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorProto_option_dependency_upb_array( + const google_protobuf_FileDescriptorProto* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 15); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -742,7 +904,9 @@ UPB_INLINE const upb_Array* _google_protobuf_FileDescriptorProto_option_dependen } return arr; } -UPB_INLINE upb_Array* _google_protobuf_FileDescriptorProto_option_dependency_mutable_upb_array(google_protobuf_FileDescriptorProto* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_FileDescriptorProto_option_dependency_mutable_upb_array( + google_protobuf_FileDescriptorProto* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 15); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -752,15 +916,16 @@ UPB_INLINE upb_Array* _google_protobuf_FileDescriptorProto_option_dependency_mut return arr; } -UPB_INLINE void google_protobuf_FileDescriptorProto_set_name(google_protobuf_FileDescriptorProto *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_FileDescriptorProto_set_name(google_protobuf_FileDescriptorProto* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 1); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FileDescriptorProto_set_package(google_protobuf_FileDescriptorProto *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_FileDescriptorProto_set_package(google_protobuf_FileDescriptorProto* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 2); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE upb_StringView* google_protobuf_FileDescriptorProto_mutable_dependency(google_protobuf_FileDescriptorProto* msg, size_t* size) { +UPB_INLINE upb_StringView* google_protobuf_FileDescriptorProto_mutable_dependency(google_protobuf_FileDescriptorProto* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 3); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -771,12 +936,16 @@ UPB_INLINE upb_StringView* google_protobuf_FileDescriptorProto_mutable_dependenc return NULL; } } -UPB_INLINE upb_StringView* google_protobuf_FileDescriptorProto_resize_dependency(google_protobuf_FileDescriptorProto* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE upb_StringView* google_protobuf_FileDescriptorProto_resize_dependency(google_protobuf_FileDescriptorProto* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 3); - return (upb_StringView*)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (upb_StringView*)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE bool google_protobuf_FileDescriptorProto_add_dependency(google_protobuf_FileDescriptorProto* msg, upb_StringView val, upb_Arena* arena) { +UPB_INLINE bool google_protobuf_FileDescriptorProto_add_dependency(google_protobuf_FileDescriptorProto* msg, upb_StringView val, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 3); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -788,7 +957,8 @@ UPB_INLINE bool google_protobuf_FileDescriptorProto_add_dependency(google_protob (arr, arr->UPB_PRIVATE(size) - 1, &val, sizeof(val)); return true; } -UPB_INLINE google_protobuf_DescriptorProto** google_protobuf_FileDescriptorProto_mutable_message_type(google_protobuf_FileDescriptorProto* msg, size_t* size) { +UPB_INLINE google_protobuf_DescriptorProto** google_protobuf_FileDescriptorProto_mutable_message_type(google_protobuf_FileDescriptorProto* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 4); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -799,12 +969,16 @@ UPB_INLINE google_protobuf_DescriptorProto** google_protobuf_FileDescriptorProto return NULL; } } -UPB_INLINE google_protobuf_DescriptorProto** google_protobuf_FileDescriptorProto_resize_message_type(google_protobuf_FileDescriptorProto* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_DescriptorProto** google_protobuf_FileDescriptorProto_resize_message_type(google_protobuf_FileDescriptorProto* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 4); - return (google_protobuf_DescriptorProto**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_DescriptorProto**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_DescriptorProto* google_protobuf_FileDescriptorProto_add_message_type(google_protobuf_FileDescriptorProto* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_DescriptorProto* google_protobuf_FileDescriptorProto_add_message_type( + google_protobuf_FileDescriptorProto* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 4); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -812,13 +986,15 @@ UPB_INLINE struct google_protobuf_DescriptorProto* google_protobuf_FileDescripto arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_DescriptorProto* sub = (struct google_protobuf_DescriptorProto*)_upb_Message_New(google__protobuf__DescriptorProto_msg_init(), arena); + struct google_protobuf_DescriptorProto* sub = + (struct google_protobuf_DescriptorProto*)_upb_Message_New(google__protobuf__DescriptorProto_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); return sub; } -UPB_INLINE google_protobuf_EnumDescriptorProto** google_protobuf_FileDescriptorProto_mutable_enum_type(google_protobuf_FileDescriptorProto* msg, size_t* size) { +UPB_INLINE google_protobuf_EnumDescriptorProto** google_protobuf_FileDescriptorProto_mutable_enum_type(google_protobuf_FileDescriptorProto* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 5); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -829,12 +1005,16 @@ UPB_INLINE google_protobuf_EnumDescriptorProto** google_protobuf_FileDescriptorP return NULL; } } -UPB_INLINE google_protobuf_EnumDescriptorProto** google_protobuf_FileDescriptorProto_resize_enum_type(google_protobuf_FileDescriptorProto* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_EnumDescriptorProto** google_protobuf_FileDescriptorProto_resize_enum_type(google_protobuf_FileDescriptorProto* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 5); - return (google_protobuf_EnumDescriptorProto**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_EnumDescriptorProto**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_EnumDescriptorProto* google_protobuf_FileDescriptorProto_add_enum_type(google_protobuf_FileDescriptorProto* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_EnumDescriptorProto* google_protobuf_FileDescriptorProto_add_enum_type( + google_protobuf_FileDescriptorProto* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 5); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -842,13 +1022,15 @@ UPB_INLINE struct google_protobuf_EnumDescriptorProto* google_protobuf_FileDescr arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_EnumDescriptorProto* sub = (struct google_protobuf_EnumDescriptorProto*)_upb_Message_New(google__protobuf__EnumDescriptorProto_msg_init(), arena); + struct google_protobuf_EnumDescriptorProto* sub = + (struct google_protobuf_EnumDescriptorProto*)_upb_Message_New(google__protobuf__EnumDescriptorProto_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); return sub; } -UPB_INLINE google_protobuf_ServiceDescriptorProto** google_protobuf_FileDescriptorProto_mutable_service(google_protobuf_FileDescriptorProto* msg, size_t* size) { +UPB_INLINE google_protobuf_ServiceDescriptorProto** google_protobuf_FileDescriptorProto_mutable_service(google_protobuf_FileDescriptorProto* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 6); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -859,12 +1041,16 @@ UPB_INLINE google_protobuf_ServiceDescriptorProto** google_protobuf_FileDescript return NULL; } } -UPB_INLINE google_protobuf_ServiceDescriptorProto** google_protobuf_FileDescriptorProto_resize_service(google_protobuf_FileDescriptorProto* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_ServiceDescriptorProto** google_protobuf_FileDescriptorProto_resize_service(google_protobuf_FileDescriptorProto* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 6); - return (google_protobuf_ServiceDescriptorProto**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_ServiceDescriptorProto**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_ServiceDescriptorProto* google_protobuf_FileDescriptorProto_add_service(google_protobuf_FileDescriptorProto* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_ServiceDescriptorProto* google_protobuf_FileDescriptorProto_add_service( + google_protobuf_FileDescriptorProto* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 6); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -872,13 +1058,15 @@ UPB_INLINE struct google_protobuf_ServiceDescriptorProto* google_protobuf_FileDe arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_ServiceDescriptorProto* sub = (struct google_protobuf_ServiceDescriptorProto*)_upb_Message_New(google__protobuf__ServiceDescriptorProto_msg_init(), arena); + struct google_protobuf_ServiceDescriptorProto* sub = + (struct google_protobuf_ServiceDescriptorProto*)_upb_Message_New(google__protobuf__ServiceDescriptorProto_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); return sub; } -UPB_INLINE google_protobuf_FieldDescriptorProto** google_protobuf_FileDescriptorProto_mutable_extension(google_protobuf_FileDescriptorProto* msg, size_t* size) { +UPB_INLINE google_protobuf_FieldDescriptorProto** google_protobuf_FileDescriptorProto_mutable_extension(google_protobuf_FileDescriptorProto* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 7); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -889,12 +1077,16 @@ UPB_INLINE google_protobuf_FieldDescriptorProto** google_protobuf_FileDescriptor return NULL; } } -UPB_INLINE google_protobuf_FieldDescriptorProto** google_protobuf_FileDescriptorProto_resize_extension(google_protobuf_FileDescriptorProto* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_FieldDescriptorProto** google_protobuf_FileDescriptorProto_resize_extension(google_protobuf_FileDescriptorProto* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 7); - return (google_protobuf_FieldDescriptorProto**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_FieldDescriptorProto**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_FieldDescriptorProto* google_protobuf_FileDescriptorProto_add_extension(google_protobuf_FileDescriptorProto* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_FieldDescriptorProto* google_protobuf_FileDescriptorProto_add_extension( + google_protobuf_FileDescriptorProto* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 7); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -902,17 +1094,19 @@ UPB_INLINE struct google_protobuf_FieldDescriptorProto* google_protobuf_FileDesc arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_FieldDescriptorProto* sub = (struct google_protobuf_FieldDescriptorProto*)_upb_Message_New(google__protobuf__FieldDescriptorProto_msg_init(), arena); + struct google_protobuf_FieldDescriptorProto* sub = + (struct google_protobuf_FieldDescriptorProto*)_upb_Message_New(google__protobuf__FieldDescriptorProto_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); return sub; } -UPB_INLINE void google_protobuf_FileDescriptorProto_set_options(google_protobuf_FileDescriptorProto *msg, google_protobuf_FileOptions* value) { +UPB_INLINE void google_protobuf_FileDescriptorProto_set_options(google_protobuf_FileDescriptorProto* msg, google_protobuf_FileOptions* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 8); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_FileOptions* google_protobuf_FileDescriptorProto_mutable_options(google_protobuf_FileDescriptorProto* msg, upb_Arena* arena) { +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); if (sub == NULL) { sub = (struct google_protobuf_FileOptions*)_upb_Message_New(google__protobuf__FileOptions_msg_init(), arena); @@ -920,11 +1114,12 @@ UPB_INLINE struct google_protobuf_FileOptions* google_protobuf_FileDescriptorPro } return sub; } -UPB_INLINE void google_protobuf_FileDescriptorProto_set_source_code_info(google_protobuf_FileDescriptorProto *msg, google_protobuf_SourceCodeInfo* value) { +UPB_INLINE void google_protobuf_FileDescriptorProto_set_source_code_info(google_protobuf_FileDescriptorProto* msg, google_protobuf_SourceCodeInfo* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 9); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_SourceCodeInfo* google_protobuf_FileDescriptorProto_mutable_source_code_info(google_protobuf_FileDescriptorProto* msg, upb_Arena* arena) { +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); if (sub == NULL) { sub = (struct google_protobuf_SourceCodeInfo*)_upb_Message_New(google__protobuf__SourceCodeInfo_msg_init(), arena); @@ -932,7 +1127,8 @@ UPB_INLINE struct google_protobuf_SourceCodeInfo* google_protobuf_FileDescriptor } return sub; } -UPB_INLINE int32_t* google_protobuf_FileDescriptorProto_mutable_public_dependency(google_protobuf_FileDescriptorProto* msg, size_t* size) { +UPB_INLINE int32_t* google_protobuf_FileDescriptorProto_mutable_public_dependency(google_protobuf_FileDescriptorProto* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 10); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -943,12 +1139,16 @@ UPB_INLINE int32_t* google_protobuf_FileDescriptorProto_mutable_public_dependenc return NULL; } } -UPB_INLINE int32_t* google_protobuf_FileDescriptorProto_resize_public_dependency(google_protobuf_FileDescriptorProto* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE int32_t* google_protobuf_FileDescriptorProto_resize_public_dependency(google_protobuf_FileDescriptorProto* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 10); - return (int32_t*)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (int32_t*)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE bool google_protobuf_FileDescriptorProto_add_public_dependency(google_protobuf_FileDescriptorProto* msg, int32_t val, upb_Arena* arena) { +UPB_INLINE bool google_protobuf_FileDescriptorProto_add_public_dependency(google_protobuf_FileDescriptorProto* msg, int32_t val, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 10); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -960,7 +1160,8 @@ UPB_INLINE bool google_protobuf_FileDescriptorProto_add_public_dependency(google (arr, arr->UPB_PRIVATE(size) - 1, &val, sizeof(val)); return true; } -UPB_INLINE int32_t* google_protobuf_FileDescriptorProto_mutable_weak_dependency(google_protobuf_FileDescriptorProto* msg, size_t* size) { +UPB_INLINE int32_t* google_protobuf_FileDescriptorProto_mutable_weak_dependency(google_protobuf_FileDescriptorProto* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 11); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -971,12 +1172,16 @@ UPB_INLINE int32_t* google_protobuf_FileDescriptorProto_mutable_weak_dependency( return NULL; } } -UPB_INLINE int32_t* google_protobuf_FileDescriptorProto_resize_weak_dependency(google_protobuf_FileDescriptorProto* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE int32_t* google_protobuf_FileDescriptorProto_resize_weak_dependency(google_protobuf_FileDescriptorProto* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 11); - return (int32_t*)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (int32_t*)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE bool google_protobuf_FileDescriptorProto_add_weak_dependency(google_protobuf_FileDescriptorProto* msg, int32_t val, upb_Arena* arena) { +UPB_INLINE bool google_protobuf_FileDescriptorProto_add_weak_dependency(google_protobuf_FileDescriptorProto* msg, int32_t val, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 11); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -988,15 +1193,16 @@ UPB_INLINE bool google_protobuf_FileDescriptorProto_add_weak_dependency(google_p (arr, arr->UPB_PRIVATE(size) - 1, &val, sizeof(val)); return true; } -UPB_INLINE void google_protobuf_FileDescriptorProto_set_syntax(google_protobuf_FileDescriptorProto *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_FileDescriptorProto_set_syntax(google_protobuf_FileDescriptorProto* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 12); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FileDescriptorProto_set_edition(google_protobuf_FileDescriptorProto *msg, int32_t value) { +UPB_INLINE void google_protobuf_FileDescriptorProto_set_edition(google_protobuf_FileDescriptorProto* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 14); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE upb_StringView* google_protobuf_FileDescriptorProto_mutable_option_dependency(google_protobuf_FileDescriptorProto* msg, size_t* size) { +UPB_INLINE upb_StringView* google_protobuf_FileDescriptorProto_mutable_option_dependency(google_protobuf_FileDescriptorProto* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 15); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -1007,12 +1213,16 @@ UPB_INLINE upb_StringView* google_protobuf_FileDescriptorProto_mutable_option_de return NULL; } } -UPB_INLINE upb_StringView* google_protobuf_FileDescriptorProto_resize_option_dependency(google_protobuf_FileDescriptorProto* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE upb_StringView* google_protobuf_FileDescriptorProto_resize_option_dependency(google_protobuf_FileDescriptorProto* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 15); - return (upb_StringView*)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (upb_StringView*)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE bool google_protobuf_FileDescriptorProto_add_option_dependency(google_protobuf_FileDescriptorProto* msg, upb_StringView val, upb_Arena* arena) { +UPB_INLINE bool google_protobuf_FileDescriptorProto_add_option_dependency(google_protobuf_FileDescriptorProto* msg, upb_StringView val, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileDescriptorProto_msg_init(), 15); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -1026,37 +1236,39 @@ UPB_INLINE bool google_protobuf_FileDescriptorProto_add_option_dependency(google } /* google.protobuf.DescriptorProto */ - UPB_INLINE google_protobuf_DescriptorProto* google_protobuf_DescriptorProto_new(upb_Arena* arena) { return (google_protobuf_DescriptorProto*)_upb_Message_New(google__protobuf__DescriptorProto_msg_init(), arena); } -UPB_INLINE google_protobuf_DescriptorProto* google_protobuf_DescriptorProto_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_DescriptorProto* google_protobuf_DescriptorProto_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_DescriptorProto* ret = google_protobuf_DescriptorProto_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__DescriptorProto_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__DescriptorProto_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_DescriptorProto* google_protobuf_DescriptorProto_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_DescriptorProto* google_protobuf_DescriptorProto_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_DescriptorProto* ret = google_protobuf_DescriptorProto_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__DescriptorProto_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__DescriptorProto_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_DescriptorProto_serialize(const google_protobuf_DescriptorProto* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_DescriptorProto_serialize(const google_protobuf_DescriptorProto* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__DescriptorProto_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_DescriptorProto_serialize_ex(const google_protobuf_DescriptorProto* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_DescriptorProto_serialize_ex(const google_protobuf_DescriptorProto* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__DescriptorProto_msg_init(), options, arena, &ptr, len); return ptr; @@ -1081,7 +1293,8 @@ UPB_INLINE void google_protobuf_DescriptorProto_clear_field(google_protobuf_Desc const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 2); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_FieldDescriptorProto* const* google_protobuf_DescriptorProto_field(const google_protobuf_DescriptorProto* msg, size_t* size) { +UPB_INLINE const google_protobuf_FieldDescriptorProto* const* google_protobuf_DescriptorProto_field(const google_protobuf_DescriptorProto* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 2); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -1092,7 +1305,10 @@ UPB_INLINE const google_protobuf_FieldDescriptorProto* const* google_protobuf_De return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_DescriptorProto_field_upb_array(const google_protobuf_DescriptorProto* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_DescriptorProto_field_upb_array( + const google_protobuf_DescriptorProto* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 2); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -1100,7 +1316,9 @@ UPB_INLINE const upb_Array* _google_protobuf_DescriptorProto_field_upb_array(con } return arr; } -UPB_INLINE upb_Array* _google_protobuf_DescriptorProto_field_mutable_upb_array(google_protobuf_DescriptorProto* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_DescriptorProto_field_mutable_upb_array( + google_protobuf_DescriptorProto* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 2); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -1113,7 +1331,8 @@ UPB_INLINE void google_protobuf_DescriptorProto_clear_nested_type(google_protobu const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 3); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_DescriptorProto* const* google_protobuf_DescriptorProto_nested_type(const google_protobuf_DescriptorProto* msg, size_t* size) { +UPB_INLINE const google_protobuf_DescriptorProto* const* google_protobuf_DescriptorProto_nested_type(const google_protobuf_DescriptorProto* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 3); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -1124,7 +1343,10 @@ UPB_INLINE const google_protobuf_DescriptorProto* const* google_protobuf_Descrip return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_DescriptorProto_nested_type_upb_array(const google_protobuf_DescriptorProto* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_DescriptorProto_nested_type_upb_array( + const google_protobuf_DescriptorProto* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 3); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -1132,7 +1354,9 @@ UPB_INLINE const upb_Array* _google_protobuf_DescriptorProto_nested_type_upb_arr } return arr; } -UPB_INLINE upb_Array* _google_protobuf_DescriptorProto_nested_type_mutable_upb_array(google_protobuf_DescriptorProto* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_DescriptorProto_nested_type_mutable_upb_array( + google_protobuf_DescriptorProto* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 3); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -1145,7 +1369,8 @@ UPB_INLINE void google_protobuf_DescriptorProto_clear_enum_type(google_protobuf_ const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 4); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_EnumDescriptorProto* const* google_protobuf_DescriptorProto_enum_type(const google_protobuf_DescriptorProto* msg, size_t* size) { +UPB_INLINE const google_protobuf_EnumDescriptorProto* const* google_protobuf_DescriptorProto_enum_type(const google_protobuf_DescriptorProto* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 4); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -1156,7 +1381,10 @@ UPB_INLINE const google_protobuf_EnumDescriptorProto* const* google_protobuf_Des return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_DescriptorProto_enum_type_upb_array(const google_protobuf_DescriptorProto* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_DescriptorProto_enum_type_upb_array( + const google_protobuf_DescriptorProto* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 4); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -1164,7 +1392,9 @@ UPB_INLINE const upb_Array* _google_protobuf_DescriptorProto_enum_type_upb_array } return arr; } -UPB_INLINE upb_Array* _google_protobuf_DescriptorProto_enum_type_mutable_upb_array(google_protobuf_DescriptorProto* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_DescriptorProto_enum_type_mutable_upb_array( + google_protobuf_DescriptorProto* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 4); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -1177,7 +1407,8 @@ UPB_INLINE void google_protobuf_DescriptorProto_clear_extension_range(google_pro const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 5); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_DescriptorProto_ExtensionRange* const* google_protobuf_DescriptorProto_extension_range(const google_protobuf_DescriptorProto* msg, size_t* size) { +UPB_INLINE const google_protobuf_DescriptorProto_ExtensionRange* const* google_protobuf_DescriptorProto_extension_range(const google_protobuf_DescriptorProto* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 5); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -1188,7 +1419,10 @@ UPB_INLINE const google_protobuf_DescriptorProto_ExtensionRange* const* google_p return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_DescriptorProto_extension_range_upb_array(const google_protobuf_DescriptorProto* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_DescriptorProto_extension_range_upb_array( + const google_protobuf_DescriptorProto* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 5); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -1196,7 +1430,9 @@ UPB_INLINE const upb_Array* _google_protobuf_DescriptorProto_extension_range_upb } return arr; } -UPB_INLINE upb_Array* _google_protobuf_DescriptorProto_extension_range_mutable_upb_array(google_protobuf_DescriptorProto* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_DescriptorProto_extension_range_mutable_upb_array( + google_protobuf_DescriptorProto* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 5); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -1209,7 +1445,8 @@ UPB_INLINE void google_protobuf_DescriptorProto_clear_extension(google_protobuf_ const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 6); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_FieldDescriptorProto* const* google_protobuf_DescriptorProto_extension(const google_protobuf_DescriptorProto* msg, size_t* size) { +UPB_INLINE const google_protobuf_FieldDescriptorProto* const* google_protobuf_DescriptorProto_extension(const google_protobuf_DescriptorProto* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 6); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -1220,7 +1457,10 @@ UPB_INLINE const google_protobuf_FieldDescriptorProto* const* google_protobuf_De return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_DescriptorProto_extension_upb_array(const google_protobuf_DescriptorProto* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_DescriptorProto_extension_upb_array( + const google_protobuf_DescriptorProto* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 6); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -1228,7 +1468,9 @@ UPB_INLINE const upb_Array* _google_protobuf_DescriptorProto_extension_upb_array } return arr; } -UPB_INLINE upb_Array* _google_protobuf_DescriptorProto_extension_mutable_upb_array(google_protobuf_DescriptorProto* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_DescriptorProto_extension_mutable_upb_array( + google_protobuf_DescriptorProto* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 6); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -1257,7 +1499,8 @@ UPB_INLINE void google_protobuf_DescriptorProto_clear_oneof_decl(google_protobuf const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 8); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_OneofDescriptorProto* const* google_protobuf_DescriptorProto_oneof_decl(const google_protobuf_DescriptorProto* msg, size_t* size) { +UPB_INLINE const google_protobuf_OneofDescriptorProto* const* google_protobuf_DescriptorProto_oneof_decl(const google_protobuf_DescriptorProto* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 8); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -1268,7 +1511,10 @@ UPB_INLINE const google_protobuf_OneofDescriptorProto* const* google_protobuf_De return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_DescriptorProto_oneof_decl_upb_array(const google_protobuf_DescriptorProto* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_DescriptorProto_oneof_decl_upb_array( + const google_protobuf_DescriptorProto* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 8); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -1276,7 +1522,9 @@ UPB_INLINE const upb_Array* _google_protobuf_DescriptorProto_oneof_decl_upb_arra } return arr; } -UPB_INLINE upb_Array* _google_protobuf_DescriptorProto_oneof_decl_mutable_upb_array(google_protobuf_DescriptorProto* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_DescriptorProto_oneof_decl_mutable_upb_array( + google_protobuf_DescriptorProto* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 8); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -1289,7 +1537,8 @@ UPB_INLINE void google_protobuf_DescriptorProto_clear_reserved_range(google_prot const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 9); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_DescriptorProto_ReservedRange* const* google_protobuf_DescriptorProto_reserved_range(const google_protobuf_DescriptorProto* msg, size_t* size) { +UPB_INLINE const google_protobuf_DescriptorProto_ReservedRange* const* google_protobuf_DescriptorProto_reserved_range(const google_protobuf_DescriptorProto* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 9); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -1300,7 +1549,10 @@ UPB_INLINE const google_protobuf_DescriptorProto_ReservedRange* const* google_pr return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_DescriptorProto_reserved_range_upb_array(const google_protobuf_DescriptorProto* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_DescriptorProto_reserved_range_upb_array( + const google_protobuf_DescriptorProto* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 9); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -1308,7 +1560,9 @@ UPB_INLINE const upb_Array* _google_protobuf_DescriptorProto_reserved_range_upb_ } return arr; } -UPB_INLINE upb_Array* _google_protobuf_DescriptorProto_reserved_range_mutable_upb_array(google_protobuf_DescriptorProto* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_DescriptorProto_reserved_range_mutable_upb_array( + google_protobuf_DescriptorProto* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 9); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -1321,7 +1575,8 @@ UPB_INLINE void google_protobuf_DescriptorProto_clear_reserved_name(google_proto const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 10); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE upb_StringView const* google_protobuf_DescriptorProto_reserved_name(const google_protobuf_DescriptorProto* msg, size_t* size) { +UPB_INLINE upb_StringView const* google_protobuf_DescriptorProto_reserved_name(const google_protobuf_DescriptorProto* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 10); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -1332,7 +1587,10 @@ UPB_INLINE upb_StringView const* google_protobuf_DescriptorProto_reserved_name(c return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_DescriptorProto_reserved_name_upb_array(const google_protobuf_DescriptorProto* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_DescriptorProto_reserved_name_upb_array( + const google_protobuf_DescriptorProto* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 10); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -1340,7 +1598,9 @@ UPB_INLINE const upb_Array* _google_protobuf_DescriptorProto_reserved_name_upb_a } return arr; } -UPB_INLINE upb_Array* _google_protobuf_DescriptorProto_reserved_name_mutable_upb_array(google_protobuf_DescriptorProto* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_DescriptorProto_reserved_name_mutable_upb_array( + google_protobuf_DescriptorProto* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 10); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -1366,11 +1626,12 @@ UPB_INLINE bool google_protobuf_DescriptorProto_has_visibility(const google_prot return upb_Message_HasBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE void google_protobuf_DescriptorProto_set_name(google_protobuf_DescriptorProto *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_DescriptorProto_set_name(google_protobuf_DescriptorProto* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 1); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE google_protobuf_FieldDescriptorProto** google_protobuf_DescriptorProto_mutable_field(google_protobuf_DescriptorProto* msg, size_t* size) { +UPB_INLINE google_protobuf_FieldDescriptorProto** google_protobuf_DescriptorProto_mutable_field(google_protobuf_DescriptorProto* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 2); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -1381,12 +1642,16 @@ UPB_INLINE google_protobuf_FieldDescriptorProto** google_protobuf_DescriptorProt return NULL; } } -UPB_INLINE google_protobuf_FieldDescriptorProto** google_protobuf_DescriptorProto_resize_field(google_protobuf_DescriptorProto* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_FieldDescriptorProto** google_protobuf_DescriptorProto_resize_field(google_protobuf_DescriptorProto* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 2); - return (google_protobuf_FieldDescriptorProto**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_FieldDescriptorProto**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_FieldDescriptorProto* google_protobuf_DescriptorProto_add_field(google_protobuf_DescriptorProto* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_FieldDescriptorProto* google_protobuf_DescriptorProto_add_field( + google_protobuf_DescriptorProto* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 2); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -1394,13 +1659,15 @@ UPB_INLINE struct google_protobuf_FieldDescriptorProto* google_protobuf_Descript arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_FieldDescriptorProto* sub = (struct google_protobuf_FieldDescriptorProto*)_upb_Message_New(google__protobuf__FieldDescriptorProto_msg_init(), arena); + struct google_protobuf_FieldDescriptorProto* sub = + (struct google_protobuf_FieldDescriptorProto*)_upb_Message_New(google__protobuf__FieldDescriptorProto_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); return sub; } -UPB_INLINE google_protobuf_DescriptorProto** google_protobuf_DescriptorProto_mutable_nested_type(google_protobuf_DescriptorProto* msg, size_t* size) { +UPB_INLINE google_protobuf_DescriptorProto** google_protobuf_DescriptorProto_mutable_nested_type(google_protobuf_DescriptorProto* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 3); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -1411,12 +1678,16 @@ UPB_INLINE google_protobuf_DescriptorProto** google_protobuf_DescriptorProto_mut return NULL; } } -UPB_INLINE google_protobuf_DescriptorProto** google_protobuf_DescriptorProto_resize_nested_type(google_protobuf_DescriptorProto* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_DescriptorProto** google_protobuf_DescriptorProto_resize_nested_type(google_protobuf_DescriptorProto* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 3); - return (google_protobuf_DescriptorProto**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_DescriptorProto**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_DescriptorProto* google_protobuf_DescriptorProto_add_nested_type(google_protobuf_DescriptorProto* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_DescriptorProto* google_protobuf_DescriptorProto_add_nested_type( + google_protobuf_DescriptorProto* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 3); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -1424,13 +1695,15 @@ UPB_INLINE struct google_protobuf_DescriptorProto* google_protobuf_DescriptorPro arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_DescriptorProto* sub = (struct google_protobuf_DescriptorProto*)_upb_Message_New(google__protobuf__DescriptorProto_msg_init(), arena); + struct google_protobuf_DescriptorProto* sub = + (struct google_protobuf_DescriptorProto*)_upb_Message_New(google__protobuf__DescriptorProto_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); return sub; } -UPB_INLINE google_protobuf_EnumDescriptorProto** google_protobuf_DescriptorProto_mutable_enum_type(google_protobuf_DescriptorProto* msg, size_t* size) { +UPB_INLINE google_protobuf_EnumDescriptorProto** google_protobuf_DescriptorProto_mutable_enum_type(google_protobuf_DescriptorProto* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 4); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -1441,12 +1714,16 @@ UPB_INLINE google_protobuf_EnumDescriptorProto** google_protobuf_DescriptorProto return NULL; } } -UPB_INLINE google_protobuf_EnumDescriptorProto** google_protobuf_DescriptorProto_resize_enum_type(google_protobuf_DescriptorProto* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_EnumDescriptorProto** google_protobuf_DescriptorProto_resize_enum_type(google_protobuf_DescriptorProto* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 4); - return (google_protobuf_EnumDescriptorProto**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_EnumDescriptorProto**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_EnumDescriptorProto* google_protobuf_DescriptorProto_add_enum_type(google_protobuf_DescriptorProto* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_EnumDescriptorProto* google_protobuf_DescriptorProto_add_enum_type( + google_protobuf_DescriptorProto* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 4); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -1454,13 +1731,15 @@ UPB_INLINE struct google_protobuf_EnumDescriptorProto* google_protobuf_Descripto arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_EnumDescriptorProto* sub = (struct google_protobuf_EnumDescriptorProto*)_upb_Message_New(google__protobuf__EnumDescriptorProto_msg_init(), arena); + struct google_protobuf_EnumDescriptorProto* sub = + (struct google_protobuf_EnumDescriptorProto*)_upb_Message_New(google__protobuf__EnumDescriptorProto_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); return sub; } -UPB_INLINE google_protobuf_DescriptorProto_ExtensionRange** google_protobuf_DescriptorProto_mutable_extension_range(google_protobuf_DescriptorProto* msg, size_t* size) { +UPB_INLINE google_protobuf_DescriptorProto_ExtensionRange** google_protobuf_DescriptorProto_mutable_extension_range(google_protobuf_DescriptorProto* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 5); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -1471,12 +1750,16 @@ UPB_INLINE google_protobuf_DescriptorProto_ExtensionRange** google_protobuf_Desc return NULL; } } -UPB_INLINE google_protobuf_DescriptorProto_ExtensionRange** google_protobuf_DescriptorProto_resize_extension_range(google_protobuf_DescriptorProto* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_DescriptorProto_ExtensionRange** google_protobuf_DescriptorProto_resize_extension_range(google_protobuf_DescriptorProto* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 5); - return (google_protobuf_DescriptorProto_ExtensionRange**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_DescriptorProto_ExtensionRange**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_DescriptorProto_ExtensionRange* google_protobuf_DescriptorProto_add_extension_range(google_protobuf_DescriptorProto* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_DescriptorProto_ExtensionRange* google_protobuf_DescriptorProto_add_extension_range( + google_protobuf_DescriptorProto* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 5); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -1484,13 +1767,15 @@ UPB_INLINE struct google_protobuf_DescriptorProto_ExtensionRange* google_protobu arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_DescriptorProto_ExtensionRange* sub = (struct google_protobuf_DescriptorProto_ExtensionRange*)_upb_Message_New(google__protobuf__DescriptorProto__ExtensionRange_msg_init(), arena); + struct google_protobuf_DescriptorProto_ExtensionRange* sub = + (struct google_protobuf_DescriptorProto_ExtensionRange*)_upb_Message_New(google__protobuf__DescriptorProto__ExtensionRange_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); return sub; } -UPB_INLINE google_protobuf_FieldDescriptorProto** google_protobuf_DescriptorProto_mutable_extension(google_protobuf_DescriptorProto* msg, size_t* size) { +UPB_INLINE google_protobuf_FieldDescriptorProto** google_protobuf_DescriptorProto_mutable_extension(google_protobuf_DescriptorProto* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 6); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -1501,12 +1786,16 @@ UPB_INLINE google_protobuf_FieldDescriptorProto** google_protobuf_DescriptorProt return NULL; } } -UPB_INLINE google_protobuf_FieldDescriptorProto** google_protobuf_DescriptorProto_resize_extension(google_protobuf_DescriptorProto* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_FieldDescriptorProto** google_protobuf_DescriptorProto_resize_extension(google_protobuf_DescriptorProto* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 6); - return (google_protobuf_FieldDescriptorProto**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_FieldDescriptorProto**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_FieldDescriptorProto* google_protobuf_DescriptorProto_add_extension(google_protobuf_DescriptorProto* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_FieldDescriptorProto* google_protobuf_DescriptorProto_add_extension( + google_protobuf_DescriptorProto* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 6); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -1514,17 +1803,19 @@ UPB_INLINE struct google_protobuf_FieldDescriptorProto* google_protobuf_Descript arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_FieldDescriptorProto* sub = (struct google_protobuf_FieldDescriptorProto*)_upb_Message_New(google__protobuf__FieldDescriptorProto_msg_init(), arena); + struct google_protobuf_FieldDescriptorProto* sub = + (struct google_protobuf_FieldDescriptorProto*)_upb_Message_New(google__protobuf__FieldDescriptorProto_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); return sub; } -UPB_INLINE void google_protobuf_DescriptorProto_set_options(google_protobuf_DescriptorProto *msg, google_protobuf_MessageOptions* value) { +UPB_INLINE void google_protobuf_DescriptorProto_set_options(google_protobuf_DescriptorProto* msg, google_protobuf_MessageOptions* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 7); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_MessageOptions* google_protobuf_DescriptorProto_mutable_options(google_protobuf_DescriptorProto* msg, upb_Arena* arena) { +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); if (sub == NULL) { sub = (struct google_protobuf_MessageOptions*)_upb_Message_New(google__protobuf__MessageOptions_msg_init(), arena); @@ -1532,7 +1823,8 @@ UPB_INLINE struct google_protobuf_MessageOptions* google_protobuf_DescriptorProt } return sub; } -UPB_INLINE google_protobuf_OneofDescriptorProto** google_protobuf_DescriptorProto_mutable_oneof_decl(google_protobuf_DescriptorProto* msg, size_t* size) { +UPB_INLINE google_protobuf_OneofDescriptorProto** google_protobuf_DescriptorProto_mutable_oneof_decl(google_protobuf_DescriptorProto* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 8); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -1543,12 +1835,16 @@ UPB_INLINE google_protobuf_OneofDescriptorProto** google_protobuf_DescriptorProt return NULL; } } -UPB_INLINE google_protobuf_OneofDescriptorProto** google_protobuf_DescriptorProto_resize_oneof_decl(google_protobuf_DescriptorProto* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_OneofDescriptorProto** google_protobuf_DescriptorProto_resize_oneof_decl(google_protobuf_DescriptorProto* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 8); - return (google_protobuf_OneofDescriptorProto**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_OneofDescriptorProto**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_OneofDescriptorProto* google_protobuf_DescriptorProto_add_oneof_decl(google_protobuf_DescriptorProto* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_OneofDescriptorProto* google_protobuf_DescriptorProto_add_oneof_decl( + google_protobuf_DescriptorProto* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 8); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -1556,13 +1852,15 @@ UPB_INLINE struct google_protobuf_OneofDescriptorProto* google_protobuf_Descript arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_OneofDescriptorProto* sub = (struct google_protobuf_OneofDescriptorProto*)_upb_Message_New(google__protobuf__OneofDescriptorProto_msg_init(), arena); + struct google_protobuf_OneofDescriptorProto* sub = + (struct google_protobuf_OneofDescriptorProto*)_upb_Message_New(google__protobuf__OneofDescriptorProto_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); return sub; } -UPB_INLINE google_protobuf_DescriptorProto_ReservedRange** google_protobuf_DescriptorProto_mutable_reserved_range(google_protobuf_DescriptorProto* msg, size_t* size) { +UPB_INLINE google_protobuf_DescriptorProto_ReservedRange** google_protobuf_DescriptorProto_mutable_reserved_range(google_protobuf_DescriptorProto* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 9); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -1573,12 +1871,16 @@ UPB_INLINE google_protobuf_DescriptorProto_ReservedRange** google_protobuf_Descr return NULL; } } -UPB_INLINE google_protobuf_DescriptorProto_ReservedRange** google_protobuf_DescriptorProto_resize_reserved_range(google_protobuf_DescriptorProto* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_DescriptorProto_ReservedRange** google_protobuf_DescriptorProto_resize_reserved_range(google_protobuf_DescriptorProto* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 9); - return (google_protobuf_DescriptorProto_ReservedRange**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_DescriptorProto_ReservedRange**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_DescriptorProto_ReservedRange* google_protobuf_DescriptorProto_add_reserved_range(google_protobuf_DescriptorProto* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_DescriptorProto_ReservedRange* google_protobuf_DescriptorProto_add_reserved_range( + google_protobuf_DescriptorProto* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 9); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -1586,13 +1888,15 @@ UPB_INLINE struct google_protobuf_DescriptorProto_ReservedRange* google_protobuf arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_DescriptorProto_ReservedRange* sub = (struct google_protobuf_DescriptorProto_ReservedRange*)_upb_Message_New(google__protobuf__DescriptorProto__ReservedRange_msg_init(), arena); + struct google_protobuf_DescriptorProto_ReservedRange* sub = + (struct google_protobuf_DescriptorProto_ReservedRange*)_upb_Message_New(google__protobuf__DescriptorProto__ReservedRange_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); return sub; } -UPB_INLINE upb_StringView* google_protobuf_DescriptorProto_mutable_reserved_name(google_protobuf_DescriptorProto* msg, size_t* size) { +UPB_INLINE upb_StringView* google_protobuf_DescriptorProto_mutable_reserved_name(google_protobuf_DescriptorProto* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 10); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -1603,12 +1907,16 @@ UPB_INLINE upb_StringView* google_protobuf_DescriptorProto_mutable_reserved_name return NULL; } } -UPB_INLINE upb_StringView* google_protobuf_DescriptorProto_resize_reserved_name(google_protobuf_DescriptorProto* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE upb_StringView* google_protobuf_DescriptorProto_resize_reserved_name(google_protobuf_DescriptorProto* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 10); - return (upb_StringView*)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (upb_StringView*)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE bool google_protobuf_DescriptorProto_add_reserved_name(google_protobuf_DescriptorProto* msg, upb_StringView val, upb_Arena* arena) { +UPB_INLINE bool google_protobuf_DescriptorProto_add_reserved_name(google_protobuf_DescriptorProto* msg, upb_StringView val, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 10); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -1620,43 +1928,45 @@ UPB_INLINE bool google_protobuf_DescriptorProto_add_reserved_name(google_protobu (arr, arr->UPB_PRIVATE(size) - 1, &val, sizeof(val)); return true; } -UPB_INLINE void google_protobuf_DescriptorProto_set_visibility(google_protobuf_DescriptorProto *msg, int32_t value) { +UPB_INLINE void google_protobuf_DescriptorProto_set_visibility(google_protobuf_DescriptorProto* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto_msg_init(), 11); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } /* google.protobuf.DescriptorProto.ExtensionRange */ - UPB_INLINE google_protobuf_DescriptorProto_ExtensionRange* google_protobuf_DescriptorProto_ExtensionRange_new(upb_Arena* arena) { return (google_protobuf_DescriptorProto_ExtensionRange*)_upb_Message_New(google__protobuf__DescriptorProto__ExtensionRange_msg_init(), arena); } -UPB_INLINE google_protobuf_DescriptorProto_ExtensionRange* google_protobuf_DescriptorProto_ExtensionRange_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_DescriptorProto_ExtensionRange* google_protobuf_DescriptorProto_ExtensionRange_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_DescriptorProto_ExtensionRange* ret = google_protobuf_DescriptorProto_ExtensionRange_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__DescriptorProto__ExtensionRange_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__DescriptorProto__ExtensionRange_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_DescriptorProto_ExtensionRange* google_protobuf_DescriptorProto_ExtensionRange_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_DescriptorProto_ExtensionRange* google_protobuf_DescriptorProto_ExtensionRange_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_DescriptorProto_ExtensionRange* ret = google_protobuf_DescriptorProto_ExtensionRange_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__DescriptorProto__ExtensionRange_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__DescriptorProto__ExtensionRange_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_DescriptorProto_ExtensionRange_serialize(const google_protobuf_DescriptorProto_ExtensionRange* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_DescriptorProto_ExtensionRange_serialize(const google_protobuf_DescriptorProto_ExtensionRange* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__DescriptorProto__ExtensionRange_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_DescriptorProto_ExtensionRange_serialize_ex(const google_protobuf_DescriptorProto_ExtensionRange* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_DescriptorProto_ExtensionRange_serialize_ex(const google_protobuf_DescriptorProto_ExtensionRange* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__DescriptorProto__ExtensionRange_msg_init(), options, arena, &ptr, len); return ptr; @@ -1710,19 +2020,20 @@ UPB_INLINE bool google_protobuf_DescriptorProto_ExtensionRange_has_options(const return upb_Message_HasBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE void google_protobuf_DescriptorProto_ExtensionRange_set_start(google_protobuf_DescriptorProto_ExtensionRange *msg, int32_t value) { +UPB_INLINE void google_protobuf_DescriptorProto_ExtensionRange_set_start(google_protobuf_DescriptorProto_ExtensionRange* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto__ExtensionRange_msg_init(), 1); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_DescriptorProto_ExtensionRange_set_end(google_protobuf_DescriptorProto_ExtensionRange *msg, int32_t value) { +UPB_INLINE void google_protobuf_DescriptorProto_ExtensionRange_set_end(google_protobuf_DescriptorProto_ExtensionRange* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto__ExtensionRange_msg_init(), 2); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_DescriptorProto_ExtensionRange_set_options(google_protobuf_DescriptorProto_ExtensionRange *msg, google_protobuf_ExtensionRangeOptions* value) { +UPB_INLINE void google_protobuf_DescriptorProto_ExtensionRange_set_options(google_protobuf_DescriptorProto_ExtensionRange* msg, google_protobuf_ExtensionRangeOptions* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto__ExtensionRange_msg_init(), 3); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_ExtensionRangeOptions* google_protobuf_DescriptorProto_ExtensionRange_mutable_options(google_protobuf_DescriptorProto_ExtensionRange* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_ExtensionRangeOptions* google_protobuf_DescriptorProto_ExtensionRange_mutable_options( + google_protobuf_DescriptorProto_ExtensionRange* msg, upb_Arena* arena) { struct google_protobuf_ExtensionRangeOptions* sub = (struct google_protobuf_ExtensionRangeOptions*)google_protobuf_DescriptorProto_ExtensionRange_options(msg); if (sub == NULL) { sub = (struct google_protobuf_ExtensionRangeOptions*)_upb_Message_New(google__protobuf__ExtensionRangeOptions_msg_init(), arena); @@ -1732,37 +2043,39 @@ UPB_INLINE struct google_protobuf_ExtensionRangeOptions* google_protobuf_Descrip } /* google.protobuf.DescriptorProto.ReservedRange */ - UPB_INLINE google_protobuf_DescriptorProto_ReservedRange* google_protobuf_DescriptorProto_ReservedRange_new(upb_Arena* arena) { return (google_protobuf_DescriptorProto_ReservedRange*)_upb_Message_New(google__protobuf__DescriptorProto__ReservedRange_msg_init(), arena); } -UPB_INLINE google_protobuf_DescriptorProto_ReservedRange* google_protobuf_DescriptorProto_ReservedRange_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_DescriptorProto_ReservedRange* google_protobuf_DescriptorProto_ReservedRange_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_DescriptorProto_ReservedRange* ret = google_protobuf_DescriptorProto_ReservedRange_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__DescriptorProto__ReservedRange_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__DescriptorProto__ReservedRange_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_DescriptorProto_ReservedRange* google_protobuf_DescriptorProto_ReservedRange_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_DescriptorProto_ReservedRange* google_protobuf_DescriptorProto_ReservedRange_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_DescriptorProto_ReservedRange* ret = google_protobuf_DescriptorProto_ReservedRange_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__DescriptorProto__ReservedRange_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__DescriptorProto__ReservedRange_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_DescriptorProto_ReservedRange_serialize(const google_protobuf_DescriptorProto_ReservedRange* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_DescriptorProto_ReservedRange_serialize(const google_protobuf_DescriptorProto_ReservedRange* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__DescriptorProto__ReservedRange_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_DescriptorProto_ReservedRange_serialize_ex(const google_protobuf_DescriptorProto_ReservedRange* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_DescriptorProto_ReservedRange_serialize_ex(const google_protobuf_DescriptorProto_ReservedRange* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__DescriptorProto__ReservedRange_msg_init(), options, arena, &ptr, len); return ptr; @@ -1800,47 +2113,49 @@ UPB_INLINE bool google_protobuf_DescriptorProto_ReservedRange_has_end(const goog return upb_Message_HasBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE void google_protobuf_DescriptorProto_ReservedRange_set_start(google_protobuf_DescriptorProto_ReservedRange *msg, int32_t value) { +UPB_INLINE void google_protobuf_DescriptorProto_ReservedRange_set_start(google_protobuf_DescriptorProto_ReservedRange* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto__ReservedRange_msg_init(), 1); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_DescriptorProto_ReservedRange_set_end(google_protobuf_DescriptorProto_ReservedRange *msg, int32_t value) { +UPB_INLINE void google_protobuf_DescriptorProto_ReservedRange_set_end(google_protobuf_DescriptorProto_ReservedRange* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__DescriptorProto__ReservedRange_msg_init(), 2); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } /* google.protobuf.ExtensionRangeOptions */ - UPB_INLINE google_protobuf_ExtensionRangeOptions* google_protobuf_ExtensionRangeOptions_new(upb_Arena* arena) { return (google_protobuf_ExtensionRangeOptions*)_upb_Message_New(google__protobuf__ExtensionRangeOptions_msg_init(), arena); } -UPB_INLINE google_protobuf_ExtensionRangeOptions* google_protobuf_ExtensionRangeOptions_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_ExtensionRangeOptions* google_protobuf_ExtensionRangeOptions_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_ExtensionRangeOptions* ret = google_protobuf_ExtensionRangeOptions_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__ExtensionRangeOptions_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__ExtensionRangeOptions_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_ExtensionRangeOptions* google_protobuf_ExtensionRangeOptions_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_ExtensionRangeOptions* google_protobuf_ExtensionRangeOptions_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_ExtensionRangeOptions* ret = google_protobuf_ExtensionRangeOptions_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__ExtensionRangeOptions_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__ExtensionRangeOptions_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_ExtensionRangeOptions_serialize(const google_protobuf_ExtensionRangeOptions* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_ExtensionRangeOptions_serialize(const google_protobuf_ExtensionRangeOptions* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__ExtensionRangeOptions_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_ExtensionRangeOptions_serialize_ex(const google_protobuf_ExtensionRangeOptions* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_ExtensionRangeOptions_serialize_ex(const google_protobuf_ExtensionRangeOptions* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__ExtensionRangeOptions_msg_init(), options, arena, &ptr, len); return ptr; @@ -1849,7 +2164,8 @@ UPB_INLINE void google_protobuf_ExtensionRangeOptions_clear_declaration(google_p const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ExtensionRangeOptions_msg_init(), 2); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_ExtensionRangeOptions_Declaration* const* google_protobuf_ExtensionRangeOptions_declaration(const google_protobuf_ExtensionRangeOptions* msg, size_t* size) { +UPB_INLINE const google_protobuf_ExtensionRangeOptions_Declaration* const* google_protobuf_ExtensionRangeOptions_declaration(const google_protobuf_ExtensionRangeOptions* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ExtensionRangeOptions_msg_init(), 2); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -1860,7 +2176,10 @@ UPB_INLINE const google_protobuf_ExtensionRangeOptions_Declaration* const* googl return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_ExtensionRangeOptions_declaration_upb_array(const google_protobuf_ExtensionRangeOptions* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_ExtensionRangeOptions_declaration_upb_array( + const google_protobuf_ExtensionRangeOptions* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ExtensionRangeOptions_msg_init(), 2); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -1868,7 +2187,9 @@ UPB_INLINE const upb_Array* _google_protobuf_ExtensionRangeOptions_declaration_u } return arr; } -UPB_INLINE upb_Array* _google_protobuf_ExtensionRangeOptions_declaration_mutable_upb_array(google_protobuf_ExtensionRangeOptions* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_ExtensionRangeOptions_declaration_mutable_upb_array( + google_protobuf_ExtensionRangeOptions* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ExtensionRangeOptions_msg_init(), 2); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -1913,7 +2234,8 @@ UPB_INLINE void google_protobuf_ExtensionRangeOptions_clear_uninterpreted_option const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ExtensionRangeOptions_msg_init(), 999); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_ExtensionRangeOptions_uninterpreted_option(const google_protobuf_ExtensionRangeOptions* msg, size_t* size) { +UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_ExtensionRangeOptions_uninterpreted_option(const google_protobuf_ExtensionRangeOptions* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ExtensionRangeOptions_msg_init(), 999); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -1924,7 +2246,10 @@ UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_Ext return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_ExtensionRangeOptions_uninterpreted_option_upb_array(const google_protobuf_ExtensionRangeOptions* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_ExtensionRangeOptions_uninterpreted_option_upb_array( + const google_protobuf_ExtensionRangeOptions* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ExtensionRangeOptions_msg_init(), 999); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -1932,7 +2257,9 @@ UPB_INLINE const upb_Array* _google_protobuf_ExtensionRangeOptions_uninterpreted } return arr; } -UPB_INLINE upb_Array* _google_protobuf_ExtensionRangeOptions_uninterpreted_option_mutable_upb_array(google_protobuf_ExtensionRangeOptions* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_ExtensionRangeOptions_uninterpreted_option_mutable_upb_array( + google_protobuf_ExtensionRangeOptions* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ExtensionRangeOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -1942,7 +2269,8 @@ UPB_INLINE upb_Array* _google_protobuf_ExtensionRangeOptions_uninterpreted_optio return arr; } -UPB_INLINE google_protobuf_ExtensionRangeOptions_Declaration** google_protobuf_ExtensionRangeOptions_mutable_declaration(google_protobuf_ExtensionRangeOptions* msg, size_t* size) { +UPB_INLINE google_protobuf_ExtensionRangeOptions_Declaration** google_protobuf_ExtensionRangeOptions_mutable_declaration(google_protobuf_ExtensionRangeOptions* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ExtensionRangeOptions_msg_init(), 2); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -1953,12 +2281,16 @@ UPB_INLINE google_protobuf_ExtensionRangeOptions_Declaration** google_protobuf_E return NULL; } } -UPB_INLINE google_protobuf_ExtensionRangeOptions_Declaration** google_protobuf_ExtensionRangeOptions_resize_declaration(google_protobuf_ExtensionRangeOptions* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_ExtensionRangeOptions_Declaration** google_protobuf_ExtensionRangeOptions_resize_declaration(google_protobuf_ExtensionRangeOptions* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ExtensionRangeOptions_msg_init(), 2); - return (google_protobuf_ExtensionRangeOptions_Declaration**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_ExtensionRangeOptions_Declaration**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_ExtensionRangeOptions_Declaration* google_protobuf_ExtensionRangeOptions_add_declaration(google_protobuf_ExtensionRangeOptions* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_ExtensionRangeOptions_Declaration* google_protobuf_ExtensionRangeOptions_add_declaration( + google_protobuf_ExtensionRangeOptions* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ExtensionRangeOptions_msg_init(), 2); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -1966,21 +2298,23 @@ UPB_INLINE struct google_protobuf_ExtensionRangeOptions_Declaration* google_prot arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_ExtensionRangeOptions_Declaration* sub = (struct google_protobuf_ExtensionRangeOptions_Declaration*)_upb_Message_New(google__protobuf__ExtensionRangeOptions__Declaration_msg_init(), arena); + struct google_protobuf_ExtensionRangeOptions_Declaration* sub = + (struct google_protobuf_ExtensionRangeOptions_Declaration*)_upb_Message_New(google__protobuf__ExtensionRangeOptions__Declaration_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); return sub; } -UPB_INLINE void google_protobuf_ExtensionRangeOptions_set_verification(google_protobuf_ExtensionRangeOptions *msg, int32_t value) { +UPB_INLINE void google_protobuf_ExtensionRangeOptions_set_verification(google_protobuf_ExtensionRangeOptions* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ExtensionRangeOptions_msg_init(), 3); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_ExtensionRangeOptions_set_features(google_protobuf_ExtensionRangeOptions *msg, google_protobuf_FeatureSet* value) { +UPB_INLINE void google_protobuf_ExtensionRangeOptions_set_features(google_protobuf_ExtensionRangeOptions* msg, google_protobuf_FeatureSet* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ExtensionRangeOptions_msg_init(), 50); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_ExtensionRangeOptions_mutable_features(google_protobuf_ExtensionRangeOptions* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_ExtensionRangeOptions_mutable_features( + google_protobuf_ExtensionRangeOptions* msg, upb_Arena* arena) { struct google_protobuf_FeatureSet* sub = (struct google_protobuf_FeatureSet*)google_protobuf_ExtensionRangeOptions_features(msg); if (sub == NULL) { sub = (struct google_protobuf_FeatureSet*)_upb_Message_New(google__protobuf__FeatureSet_msg_init(), arena); @@ -1988,7 +2322,8 @@ UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_ExtensionRangeOpti } return sub; } -UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_ExtensionRangeOptions_mutable_uninterpreted_option(google_protobuf_ExtensionRangeOptions* msg, size_t* size) { +UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_ExtensionRangeOptions_mutable_uninterpreted_option(google_protobuf_ExtensionRangeOptions* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ExtensionRangeOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -1999,12 +2334,16 @@ UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_ExtensionRangeO return NULL; } } -UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_ExtensionRangeOptions_resize_uninterpreted_option(google_protobuf_ExtensionRangeOptions* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_ExtensionRangeOptions_resize_uninterpreted_option(google_protobuf_ExtensionRangeOptions* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ExtensionRangeOptions_msg_init(), 999); - return (google_protobuf_UninterpretedOption**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_UninterpretedOption**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_ExtensionRangeOptions_add_uninterpreted_option(google_protobuf_ExtensionRangeOptions* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_ExtensionRangeOptions_add_uninterpreted_option( + google_protobuf_ExtensionRangeOptions* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ExtensionRangeOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -2012,7 +2351,8 @@ UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_Extension arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_UninterpretedOption* sub = (struct google_protobuf_UninterpretedOption*)_upb_Message_New(google__protobuf__UninterpretedOption_msg_init(), arena); + struct google_protobuf_UninterpretedOption* sub = + (struct google_protobuf_UninterpretedOption*)_upb_Message_New(google__protobuf__UninterpretedOption_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); @@ -2020,37 +2360,39 @@ UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_Extension } /* google.protobuf.ExtensionRangeOptions.Declaration */ - UPB_INLINE google_protobuf_ExtensionRangeOptions_Declaration* google_protobuf_ExtensionRangeOptions_Declaration_new(upb_Arena* arena) { return (google_protobuf_ExtensionRangeOptions_Declaration*)_upb_Message_New(google__protobuf__ExtensionRangeOptions__Declaration_msg_init(), arena); } -UPB_INLINE google_protobuf_ExtensionRangeOptions_Declaration* google_protobuf_ExtensionRangeOptions_Declaration_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_ExtensionRangeOptions_Declaration* google_protobuf_ExtensionRangeOptions_Declaration_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_ExtensionRangeOptions_Declaration* ret = google_protobuf_ExtensionRangeOptions_Declaration_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__ExtensionRangeOptions__Declaration_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__ExtensionRangeOptions__Declaration_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_ExtensionRangeOptions_Declaration* google_protobuf_ExtensionRangeOptions_Declaration_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_ExtensionRangeOptions_Declaration* google_protobuf_ExtensionRangeOptions_Declaration_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_ExtensionRangeOptions_Declaration* ret = google_protobuf_ExtensionRangeOptions_Declaration_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__ExtensionRangeOptions__Declaration_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__ExtensionRangeOptions__Declaration_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_ExtensionRangeOptions_Declaration_serialize(const google_protobuf_ExtensionRangeOptions_Declaration* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_ExtensionRangeOptions_Declaration_serialize(const google_protobuf_ExtensionRangeOptions_Declaration* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__ExtensionRangeOptions__Declaration_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_ExtensionRangeOptions_Declaration_serialize_ex(const google_protobuf_ExtensionRangeOptions_Declaration* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_ExtensionRangeOptions_Declaration_serialize_ex(const google_protobuf_ExtensionRangeOptions_Declaration* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__ExtensionRangeOptions__Declaration_msg_init(), options, arena, &ptr, len); return ptr; @@ -2136,59 +2478,61 @@ UPB_INLINE bool google_protobuf_ExtensionRangeOptions_Declaration_has_repeated(c return upb_Message_HasBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE void google_protobuf_ExtensionRangeOptions_Declaration_set_number(google_protobuf_ExtensionRangeOptions_Declaration *msg, int32_t value) { +UPB_INLINE void google_protobuf_ExtensionRangeOptions_Declaration_set_number(google_protobuf_ExtensionRangeOptions_Declaration* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ExtensionRangeOptions__Declaration_msg_init(), 1); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_ExtensionRangeOptions_Declaration_set_full_name(google_protobuf_ExtensionRangeOptions_Declaration *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_ExtensionRangeOptions_Declaration_set_full_name(google_protobuf_ExtensionRangeOptions_Declaration* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ExtensionRangeOptions__Declaration_msg_init(), 2); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_ExtensionRangeOptions_Declaration_set_type(google_protobuf_ExtensionRangeOptions_Declaration *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_ExtensionRangeOptions_Declaration_set_type(google_protobuf_ExtensionRangeOptions_Declaration* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ExtensionRangeOptions__Declaration_msg_init(), 3); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_ExtensionRangeOptions_Declaration_set_reserved(google_protobuf_ExtensionRangeOptions_Declaration *msg, bool value) { +UPB_INLINE void google_protobuf_ExtensionRangeOptions_Declaration_set_reserved(google_protobuf_ExtensionRangeOptions_Declaration* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ExtensionRangeOptions__Declaration_msg_init(), 5); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_ExtensionRangeOptions_Declaration_set_repeated(google_protobuf_ExtensionRangeOptions_Declaration *msg, bool value) { +UPB_INLINE void google_protobuf_ExtensionRangeOptions_Declaration_set_repeated(google_protobuf_ExtensionRangeOptions_Declaration* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ExtensionRangeOptions__Declaration_msg_init(), 6); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } /* google.protobuf.FieldDescriptorProto */ - UPB_INLINE google_protobuf_FieldDescriptorProto* google_protobuf_FieldDescriptorProto_new(upb_Arena* arena) { return (google_protobuf_FieldDescriptorProto*)_upb_Message_New(google__protobuf__FieldDescriptorProto_msg_init(), arena); } -UPB_INLINE google_protobuf_FieldDescriptorProto* google_protobuf_FieldDescriptorProto_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_FieldDescriptorProto* google_protobuf_FieldDescriptorProto_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_FieldDescriptorProto* ret = google_protobuf_FieldDescriptorProto_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FieldDescriptorProto_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FieldDescriptorProto_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_FieldDescriptorProto* google_protobuf_FieldDescriptorProto_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_FieldDescriptorProto* google_protobuf_FieldDescriptorProto_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_FieldDescriptorProto* ret = google_protobuf_FieldDescriptorProto_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FieldDescriptorProto_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FieldDescriptorProto_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_FieldDescriptorProto_serialize(const google_protobuf_FieldDescriptorProto* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_FieldDescriptorProto_serialize(const google_protobuf_FieldDescriptorProto* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__FieldDescriptorProto_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_FieldDescriptorProto_serialize_ex(const google_protobuf_FieldDescriptorProto* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_FieldDescriptorProto_serialize_ex(const google_protobuf_FieldDescriptorProto* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__FieldDescriptorProto_msg_init(), options, arena, &ptr, len); return ptr; @@ -2370,39 +2714,40 @@ UPB_INLINE bool google_protobuf_FieldDescriptorProto_has_proto3_optional(const g return upb_Message_HasBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE void google_protobuf_FieldDescriptorProto_set_name(google_protobuf_FieldDescriptorProto *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_FieldDescriptorProto_set_name(google_protobuf_FieldDescriptorProto* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldDescriptorProto_msg_init(), 1); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FieldDescriptorProto_set_extendee(google_protobuf_FieldDescriptorProto *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_FieldDescriptorProto_set_extendee(google_protobuf_FieldDescriptorProto* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldDescriptorProto_msg_init(), 2); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FieldDescriptorProto_set_number(google_protobuf_FieldDescriptorProto *msg, int32_t value) { +UPB_INLINE void google_protobuf_FieldDescriptorProto_set_number(google_protobuf_FieldDescriptorProto* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldDescriptorProto_msg_init(), 3); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FieldDescriptorProto_set_label(google_protobuf_FieldDescriptorProto *msg, int32_t value) { +UPB_INLINE void google_protobuf_FieldDescriptorProto_set_label(google_protobuf_FieldDescriptorProto* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldDescriptorProto_msg_init(), 4); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FieldDescriptorProto_set_type(google_protobuf_FieldDescriptorProto *msg, int32_t value) { +UPB_INLINE void google_protobuf_FieldDescriptorProto_set_type(google_protobuf_FieldDescriptorProto* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldDescriptorProto_msg_init(), 5); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FieldDescriptorProto_set_type_name(google_protobuf_FieldDescriptorProto *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_FieldDescriptorProto_set_type_name(google_protobuf_FieldDescriptorProto* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldDescriptorProto_msg_init(), 6); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FieldDescriptorProto_set_default_value(google_protobuf_FieldDescriptorProto *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_FieldDescriptorProto_set_default_value(google_protobuf_FieldDescriptorProto* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldDescriptorProto_msg_init(), 7); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FieldDescriptorProto_set_options(google_protobuf_FieldDescriptorProto *msg, google_protobuf_FieldOptions* value) { +UPB_INLINE void google_protobuf_FieldDescriptorProto_set_options(google_protobuf_FieldDescriptorProto* msg, google_protobuf_FieldOptions* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldDescriptorProto_msg_init(), 8); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_FieldOptions* google_protobuf_FieldDescriptorProto_mutable_options(google_protobuf_FieldDescriptorProto* msg, upb_Arena* arena) { +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); if (sub == NULL) { sub = (struct google_protobuf_FieldOptions*)_upb_Message_New(google__protobuf__FieldOptions_msg_init(), arena); @@ -2410,51 +2755,53 @@ UPB_INLINE struct google_protobuf_FieldOptions* google_protobuf_FieldDescriptorP } return sub; } -UPB_INLINE void google_protobuf_FieldDescriptorProto_set_oneof_index(google_protobuf_FieldDescriptorProto *msg, int32_t value) { +UPB_INLINE void google_protobuf_FieldDescriptorProto_set_oneof_index(google_protobuf_FieldDescriptorProto* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldDescriptorProto_msg_init(), 9); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FieldDescriptorProto_set_json_name(google_protobuf_FieldDescriptorProto *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_FieldDescriptorProto_set_json_name(google_protobuf_FieldDescriptorProto* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldDescriptorProto_msg_init(), 10); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FieldDescriptorProto_set_proto3_optional(google_protobuf_FieldDescriptorProto *msg, bool value) { +UPB_INLINE void google_protobuf_FieldDescriptorProto_set_proto3_optional(google_protobuf_FieldDescriptorProto* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldDescriptorProto_msg_init(), 17); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } /* google.protobuf.OneofDescriptorProto */ - UPB_INLINE google_protobuf_OneofDescriptorProto* google_protobuf_OneofDescriptorProto_new(upb_Arena* arena) { return (google_protobuf_OneofDescriptorProto*)_upb_Message_New(google__protobuf__OneofDescriptorProto_msg_init(), arena); } -UPB_INLINE google_protobuf_OneofDescriptorProto* google_protobuf_OneofDescriptorProto_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_OneofDescriptorProto* google_protobuf_OneofDescriptorProto_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_OneofDescriptorProto* ret = google_protobuf_OneofDescriptorProto_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__OneofDescriptorProto_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__OneofDescriptorProto_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_OneofDescriptorProto* google_protobuf_OneofDescriptorProto_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_OneofDescriptorProto* google_protobuf_OneofDescriptorProto_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_OneofDescriptorProto* ret = google_protobuf_OneofDescriptorProto_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__OneofDescriptorProto_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__OneofDescriptorProto_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_OneofDescriptorProto_serialize(const google_protobuf_OneofDescriptorProto* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_OneofDescriptorProto_serialize(const google_protobuf_OneofDescriptorProto* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__OneofDescriptorProto_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_OneofDescriptorProto_serialize_ex(const google_protobuf_OneofDescriptorProto* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_OneofDescriptorProto_serialize_ex(const google_protobuf_OneofDescriptorProto* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__OneofDescriptorProto_msg_init(), options, arena, &ptr, len); return ptr; @@ -2492,15 +2839,16 @@ UPB_INLINE bool google_protobuf_OneofDescriptorProto_has_options(const google_pr return upb_Message_HasBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE void google_protobuf_OneofDescriptorProto_set_name(google_protobuf_OneofDescriptorProto *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_OneofDescriptorProto_set_name(google_protobuf_OneofDescriptorProto* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__OneofDescriptorProto_msg_init(), 1); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_OneofDescriptorProto_set_options(google_protobuf_OneofDescriptorProto *msg, google_protobuf_OneofOptions* value) { +UPB_INLINE void google_protobuf_OneofDescriptorProto_set_options(google_protobuf_OneofDescriptorProto* msg, google_protobuf_OneofOptions* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__OneofDescriptorProto_msg_init(), 2); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_OneofOptions* google_protobuf_OneofDescriptorProto_mutable_options(google_protobuf_OneofDescriptorProto* msg, upb_Arena* arena) { +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); if (sub == NULL) { sub = (struct google_protobuf_OneofOptions*)_upb_Message_New(google__protobuf__OneofOptions_msg_init(), arena); @@ -2510,37 +2858,39 @@ UPB_INLINE struct google_protobuf_OneofOptions* google_protobuf_OneofDescriptorP } /* google.protobuf.EnumDescriptorProto */ - UPB_INLINE google_protobuf_EnumDescriptorProto* google_protobuf_EnumDescriptorProto_new(upb_Arena* arena) { return (google_protobuf_EnumDescriptorProto*)_upb_Message_New(google__protobuf__EnumDescriptorProto_msg_init(), arena); } -UPB_INLINE google_protobuf_EnumDescriptorProto* google_protobuf_EnumDescriptorProto_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_EnumDescriptorProto* google_protobuf_EnumDescriptorProto_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_EnumDescriptorProto* ret = google_protobuf_EnumDescriptorProto_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__EnumDescriptorProto_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__EnumDescriptorProto_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_EnumDescriptorProto* google_protobuf_EnumDescriptorProto_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_EnumDescriptorProto* google_protobuf_EnumDescriptorProto_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_EnumDescriptorProto* ret = google_protobuf_EnumDescriptorProto_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__EnumDescriptorProto_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__EnumDescriptorProto_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_EnumDescriptorProto_serialize(const google_protobuf_EnumDescriptorProto* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_EnumDescriptorProto_serialize(const google_protobuf_EnumDescriptorProto* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__EnumDescriptorProto_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_EnumDescriptorProto_serialize_ex(const google_protobuf_EnumDescriptorProto* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_EnumDescriptorProto_serialize_ex(const google_protobuf_EnumDescriptorProto* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__EnumDescriptorProto_msg_init(), options, arena, &ptr, len); return ptr; @@ -2565,7 +2915,8 @@ UPB_INLINE void google_protobuf_EnumDescriptorProto_clear_value(google_protobuf_ const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto_msg_init(), 2); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_EnumValueDescriptorProto* const* google_protobuf_EnumDescriptorProto_value(const google_protobuf_EnumDescriptorProto* msg, size_t* size) { +UPB_INLINE const google_protobuf_EnumValueDescriptorProto* const* google_protobuf_EnumDescriptorProto_value(const google_protobuf_EnumDescriptorProto* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto_msg_init(), 2); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -2576,7 +2927,10 @@ UPB_INLINE const google_protobuf_EnumValueDescriptorProto* const* google_protobu return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_EnumDescriptorProto_value_upb_array(const google_protobuf_EnumDescriptorProto* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_EnumDescriptorProto_value_upb_array( + const google_protobuf_EnumDescriptorProto* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto_msg_init(), 2); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -2584,7 +2938,9 @@ UPB_INLINE const upb_Array* _google_protobuf_EnumDescriptorProto_value_upb_array } return arr; } -UPB_INLINE upb_Array* _google_protobuf_EnumDescriptorProto_value_mutable_upb_array(google_protobuf_EnumDescriptorProto* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_EnumDescriptorProto_value_mutable_upb_array( + google_protobuf_EnumDescriptorProto* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto_msg_init(), 2); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -2613,7 +2969,8 @@ UPB_INLINE void google_protobuf_EnumDescriptorProto_clear_reserved_range(google_ const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto_msg_init(), 4); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_EnumDescriptorProto_EnumReservedRange* const* google_protobuf_EnumDescriptorProto_reserved_range(const google_protobuf_EnumDescriptorProto* msg, size_t* size) { +UPB_INLINE const google_protobuf_EnumDescriptorProto_EnumReservedRange* const* google_protobuf_EnumDescriptorProto_reserved_range(const google_protobuf_EnumDescriptorProto* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto_msg_init(), 4); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -2624,7 +2981,10 @@ UPB_INLINE const google_protobuf_EnumDescriptorProto_EnumReservedRange* const* g return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_EnumDescriptorProto_reserved_range_upb_array(const google_protobuf_EnumDescriptorProto* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_EnumDescriptorProto_reserved_range_upb_array( + const google_protobuf_EnumDescriptorProto* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto_msg_init(), 4); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -2632,7 +2992,9 @@ UPB_INLINE const upb_Array* _google_protobuf_EnumDescriptorProto_reserved_range_ } return arr; } -UPB_INLINE upb_Array* _google_protobuf_EnumDescriptorProto_reserved_range_mutable_upb_array(google_protobuf_EnumDescriptorProto* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_EnumDescriptorProto_reserved_range_mutable_upb_array( + google_protobuf_EnumDescriptorProto* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto_msg_init(), 4); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -2645,7 +3007,8 @@ UPB_INLINE void google_protobuf_EnumDescriptorProto_clear_reserved_name(google_p const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto_msg_init(), 5); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE upb_StringView const* google_protobuf_EnumDescriptorProto_reserved_name(const google_protobuf_EnumDescriptorProto* msg, size_t* size) { +UPB_INLINE upb_StringView const* google_protobuf_EnumDescriptorProto_reserved_name(const google_protobuf_EnumDescriptorProto* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto_msg_init(), 5); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -2656,7 +3019,10 @@ UPB_INLINE upb_StringView const* google_protobuf_EnumDescriptorProto_reserved_na return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_EnumDescriptorProto_reserved_name_upb_array(const google_protobuf_EnumDescriptorProto* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_EnumDescriptorProto_reserved_name_upb_array( + const google_protobuf_EnumDescriptorProto* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto_msg_init(), 5); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -2664,7 +3030,9 @@ UPB_INLINE const upb_Array* _google_protobuf_EnumDescriptorProto_reserved_name_u } return arr; } -UPB_INLINE upb_Array* _google_protobuf_EnumDescriptorProto_reserved_name_mutable_upb_array(google_protobuf_EnumDescriptorProto* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_EnumDescriptorProto_reserved_name_mutable_upb_array( + google_protobuf_EnumDescriptorProto* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto_msg_init(), 5); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -2690,11 +3058,12 @@ UPB_INLINE bool google_protobuf_EnumDescriptorProto_has_visibility(const google_ return upb_Message_HasBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE void google_protobuf_EnumDescriptorProto_set_name(google_protobuf_EnumDescriptorProto *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_EnumDescriptorProto_set_name(google_protobuf_EnumDescriptorProto* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto_msg_init(), 1); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE google_protobuf_EnumValueDescriptorProto** google_protobuf_EnumDescriptorProto_mutable_value(google_protobuf_EnumDescriptorProto* msg, size_t* size) { +UPB_INLINE google_protobuf_EnumValueDescriptorProto** google_protobuf_EnumDescriptorProto_mutable_value(google_protobuf_EnumDescriptorProto* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto_msg_init(), 2); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -2705,12 +3074,16 @@ UPB_INLINE google_protobuf_EnumValueDescriptorProto** google_protobuf_EnumDescri return NULL; } } -UPB_INLINE google_protobuf_EnumValueDescriptorProto** google_protobuf_EnumDescriptorProto_resize_value(google_protobuf_EnumDescriptorProto* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_EnumValueDescriptorProto** google_protobuf_EnumDescriptorProto_resize_value(google_protobuf_EnumDescriptorProto* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto_msg_init(), 2); - return (google_protobuf_EnumValueDescriptorProto**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_EnumValueDescriptorProto**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_EnumValueDescriptorProto* google_protobuf_EnumDescriptorProto_add_value(google_protobuf_EnumDescriptorProto* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_EnumValueDescriptorProto* google_protobuf_EnumDescriptorProto_add_value( + google_protobuf_EnumDescriptorProto* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto_msg_init(), 2); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -2718,17 +3091,19 @@ UPB_INLINE struct google_protobuf_EnumValueDescriptorProto* google_protobuf_Enum arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_EnumValueDescriptorProto* sub = (struct google_protobuf_EnumValueDescriptorProto*)_upb_Message_New(google__protobuf__EnumValueDescriptorProto_msg_init(), arena); + struct google_protobuf_EnumValueDescriptorProto* sub = + (struct google_protobuf_EnumValueDescriptorProto*)_upb_Message_New(google__protobuf__EnumValueDescriptorProto_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); return sub; } -UPB_INLINE void google_protobuf_EnumDescriptorProto_set_options(google_protobuf_EnumDescriptorProto *msg, google_protobuf_EnumOptions* value) { +UPB_INLINE void google_protobuf_EnumDescriptorProto_set_options(google_protobuf_EnumDescriptorProto* msg, google_protobuf_EnumOptions* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto_msg_init(), 3); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_EnumOptions* google_protobuf_EnumDescriptorProto_mutable_options(google_protobuf_EnumDescriptorProto* msg, upb_Arena* arena) { +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); if (sub == NULL) { sub = (struct google_protobuf_EnumOptions*)_upb_Message_New(google__protobuf__EnumOptions_msg_init(), arena); @@ -2736,7 +3111,8 @@ UPB_INLINE struct google_protobuf_EnumOptions* google_protobuf_EnumDescriptorPro } return sub; } -UPB_INLINE google_protobuf_EnumDescriptorProto_EnumReservedRange** google_protobuf_EnumDescriptorProto_mutable_reserved_range(google_protobuf_EnumDescriptorProto* msg, size_t* size) { +UPB_INLINE google_protobuf_EnumDescriptorProto_EnumReservedRange** google_protobuf_EnumDescriptorProto_mutable_reserved_range(google_protobuf_EnumDescriptorProto* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto_msg_init(), 4); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -2747,12 +3123,16 @@ UPB_INLINE google_protobuf_EnumDescriptorProto_EnumReservedRange** google_protob return NULL; } } -UPB_INLINE google_protobuf_EnumDescriptorProto_EnumReservedRange** google_protobuf_EnumDescriptorProto_resize_reserved_range(google_protobuf_EnumDescriptorProto* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_EnumDescriptorProto_EnumReservedRange** google_protobuf_EnumDescriptorProto_resize_reserved_range(google_protobuf_EnumDescriptorProto* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto_msg_init(), 4); - return (google_protobuf_EnumDescriptorProto_EnumReservedRange**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_EnumDescriptorProto_EnumReservedRange**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_EnumDescriptorProto_EnumReservedRange* google_protobuf_EnumDescriptorProto_add_reserved_range(google_protobuf_EnumDescriptorProto* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_EnumDescriptorProto_EnumReservedRange* google_protobuf_EnumDescriptorProto_add_reserved_range( + google_protobuf_EnumDescriptorProto* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto_msg_init(), 4); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -2760,13 +3140,15 @@ UPB_INLINE struct google_protobuf_EnumDescriptorProto_EnumReservedRange* google_ arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_EnumDescriptorProto_EnumReservedRange* sub = (struct google_protobuf_EnumDescriptorProto_EnumReservedRange*)_upb_Message_New(google__protobuf__EnumDescriptorProto__EnumReservedRange_msg_init(), arena); + struct google_protobuf_EnumDescriptorProto_EnumReservedRange* sub = + (struct google_protobuf_EnumDescriptorProto_EnumReservedRange*)_upb_Message_New(google__protobuf__EnumDescriptorProto__EnumReservedRange_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); return sub; } -UPB_INLINE upb_StringView* google_protobuf_EnumDescriptorProto_mutable_reserved_name(google_protobuf_EnumDescriptorProto* msg, size_t* size) { +UPB_INLINE upb_StringView* google_protobuf_EnumDescriptorProto_mutable_reserved_name(google_protobuf_EnumDescriptorProto* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto_msg_init(), 5); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -2777,12 +3159,16 @@ UPB_INLINE upb_StringView* google_protobuf_EnumDescriptorProto_mutable_reserved_ return NULL; } } -UPB_INLINE upb_StringView* google_protobuf_EnumDescriptorProto_resize_reserved_name(google_protobuf_EnumDescriptorProto* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE upb_StringView* google_protobuf_EnumDescriptorProto_resize_reserved_name(google_protobuf_EnumDescriptorProto* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto_msg_init(), 5); - return (upb_StringView*)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (upb_StringView*)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE bool google_protobuf_EnumDescriptorProto_add_reserved_name(google_protobuf_EnumDescriptorProto* msg, upb_StringView val, upb_Arena* arena) { +UPB_INLINE bool google_protobuf_EnumDescriptorProto_add_reserved_name(google_protobuf_EnumDescriptorProto* msg, upb_StringView val, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto_msg_init(), 5); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -2794,43 +3180,45 @@ UPB_INLINE bool google_protobuf_EnumDescriptorProto_add_reserved_name(google_pro (arr, arr->UPB_PRIVATE(size) - 1, &val, sizeof(val)); return true; } -UPB_INLINE void google_protobuf_EnumDescriptorProto_set_visibility(google_protobuf_EnumDescriptorProto *msg, int32_t value) { +UPB_INLINE void google_protobuf_EnumDescriptorProto_set_visibility(google_protobuf_EnumDescriptorProto* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto_msg_init(), 6); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } /* google.protobuf.EnumDescriptorProto.EnumReservedRange */ - UPB_INLINE google_protobuf_EnumDescriptorProto_EnumReservedRange* google_protobuf_EnumDescriptorProto_EnumReservedRange_new(upb_Arena* arena) { return (google_protobuf_EnumDescriptorProto_EnumReservedRange*)_upb_Message_New(google__protobuf__EnumDescriptorProto__EnumReservedRange_msg_init(), arena); } -UPB_INLINE google_protobuf_EnumDescriptorProto_EnumReservedRange* google_protobuf_EnumDescriptorProto_EnumReservedRange_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_EnumDescriptorProto_EnumReservedRange* google_protobuf_EnumDescriptorProto_EnumReservedRange_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_EnumDescriptorProto_EnumReservedRange* ret = google_protobuf_EnumDescriptorProto_EnumReservedRange_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__EnumDescriptorProto__EnumReservedRange_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__EnumDescriptorProto__EnumReservedRange_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_EnumDescriptorProto_EnumReservedRange* google_protobuf_EnumDescriptorProto_EnumReservedRange_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_EnumDescriptorProto_EnumReservedRange* google_protobuf_EnumDescriptorProto_EnumReservedRange_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_EnumDescriptorProto_EnumReservedRange* ret = google_protobuf_EnumDescriptorProto_EnumReservedRange_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__EnumDescriptorProto__EnumReservedRange_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__EnumDescriptorProto__EnumReservedRange_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_EnumDescriptorProto_EnumReservedRange_serialize(const google_protobuf_EnumDescriptorProto_EnumReservedRange* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_EnumDescriptorProto_EnumReservedRange_serialize(const google_protobuf_EnumDescriptorProto_EnumReservedRange* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__EnumDescriptorProto__EnumReservedRange_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_EnumDescriptorProto_EnumReservedRange_serialize_ex(const google_protobuf_EnumDescriptorProto_EnumReservedRange* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_EnumDescriptorProto_EnumReservedRange_serialize_ex(const google_protobuf_EnumDescriptorProto_EnumReservedRange* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__EnumDescriptorProto__EnumReservedRange_msg_init(), options, arena, &ptr, len); return ptr; @@ -2868,47 +3256,49 @@ UPB_INLINE bool google_protobuf_EnumDescriptorProto_EnumReservedRange_has_end(co return upb_Message_HasBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE void google_protobuf_EnumDescriptorProto_EnumReservedRange_set_start(google_protobuf_EnumDescriptorProto_EnumReservedRange *msg, int32_t value) { +UPB_INLINE void google_protobuf_EnumDescriptorProto_EnumReservedRange_set_start(google_protobuf_EnumDescriptorProto_EnumReservedRange* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto__EnumReservedRange_msg_init(), 1); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_EnumDescriptorProto_EnumReservedRange_set_end(google_protobuf_EnumDescriptorProto_EnumReservedRange *msg, int32_t value) { +UPB_INLINE void google_protobuf_EnumDescriptorProto_EnumReservedRange_set_end(google_protobuf_EnumDescriptorProto_EnumReservedRange* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumDescriptorProto__EnumReservedRange_msg_init(), 2); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } /* google.protobuf.EnumValueDescriptorProto */ - UPB_INLINE google_protobuf_EnumValueDescriptorProto* google_protobuf_EnumValueDescriptorProto_new(upb_Arena* arena) { return (google_protobuf_EnumValueDescriptorProto*)_upb_Message_New(google__protobuf__EnumValueDescriptorProto_msg_init(), arena); } -UPB_INLINE google_protobuf_EnumValueDescriptorProto* google_protobuf_EnumValueDescriptorProto_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_EnumValueDescriptorProto* google_protobuf_EnumValueDescriptorProto_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_EnumValueDescriptorProto* ret = google_protobuf_EnumValueDescriptorProto_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__EnumValueDescriptorProto_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__EnumValueDescriptorProto_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_EnumValueDescriptorProto* google_protobuf_EnumValueDescriptorProto_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_EnumValueDescriptorProto* google_protobuf_EnumValueDescriptorProto_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_EnumValueDescriptorProto* ret = google_protobuf_EnumValueDescriptorProto_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__EnumValueDescriptorProto_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__EnumValueDescriptorProto_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_EnumValueDescriptorProto_serialize(const google_protobuf_EnumValueDescriptorProto* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_EnumValueDescriptorProto_serialize(const google_protobuf_EnumValueDescriptorProto* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__EnumValueDescriptorProto_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_EnumValueDescriptorProto_serialize_ex(const google_protobuf_EnumValueDescriptorProto* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_EnumValueDescriptorProto_serialize_ex(const google_protobuf_EnumValueDescriptorProto* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__EnumValueDescriptorProto_msg_init(), options, arena, &ptr, len); return ptr; @@ -2962,19 +3352,20 @@ UPB_INLINE bool google_protobuf_EnumValueDescriptorProto_has_options(const googl return upb_Message_HasBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE void google_protobuf_EnumValueDescriptorProto_set_name(google_protobuf_EnumValueDescriptorProto *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_EnumValueDescriptorProto_set_name(google_protobuf_EnumValueDescriptorProto* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumValueDescriptorProto_msg_init(), 1); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_EnumValueDescriptorProto_set_number(google_protobuf_EnumValueDescriptorProto *msg, int32_t value) { +UPB_INLINE void google_protobuf_EnumValueDescriptorProto_set_number(google_protobuf_EnumValueDescriptorProto* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumValueDescriptorProto_msg_init(), 2); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_EnumValueDescriptorProto_set_options(google_protobuf_EnumValueDescriptorProto *msg, google_protobuf_EnumValueOptions* value) { +UPB_INLINE void google_protobuf_EnumValueDescriptorProto_set_options(google_protobuf_EnumValueDescriptorProto* msg, google_protobuf_EnumValueOptions* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumValueDescriptorProto_msg_init(), 3); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_EnumValueOptions* google_protobuf_EnumValueDescriptorProto_mutable_options(google_protobuf_EnumValueDescriptorProto* msg, upb_Arena* arena) { +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); if (sub == NULL) { sub = (struct google_protobuf_EnumValueOptions*)_upb_Message_New(google__protobuf__EnumValueOptions_msg_init(), arena); @@ -2984,37 +3375,39 @@ UPB_INLINE struct google_protobuf_EnumValueOptions* google_protobuf_EnumValueDes } /* google.protobuf.ServiceDescriptorProto */ - UPB_INLINE google_protobuf_ServiceDescriptorProto* google_protobuf_ServiceDescriptorProto_new(upb_Arena* arena) { return (google_protobuf_ServiceDescriptorProto*)_upb_Message_New(google__protobuf__ServiceDescriptorProto_msg_init(), arena); } -UPB_INLINE google_protobuf_ServiceDescriptorProto* google_protobuf_ServiceDescriptorProto_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_ServiceDescriptorProto* google_protobuf_ServiceDescriptorProto_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_ServiceDescriptorProto* ret = google_protobuf_ServiceDescriptorProto_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__ServiceDescriptorProto_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__ServiceDescriptorProto_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_ServiceDescriptorProto* google_protobuf_ServiceDescriptorProto_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_ServiceDescriptorProto* google_protobuf_ServiceDescriptorProto_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_ServiceDescriptorProto* ret = google_protobuf_ServiceDescriptorProto_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__ServiceDescriptorProto_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__ServiceDescriptorProto_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_ServiceDescriptorProto_serialize(const google_protobuf_ServiceDescriptorProto* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_ServiceDescriptorProto_serialize(const google_protobuf_ServiceDescriptorProto* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__ServiceDescriptorProto_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_ServiceDescriptorProto_serialize_ex(const google_protobuf_ServiceDescriptorProto* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_ServiceDescriptorProto_serialize_ex(const google_protobuf_ServiceDescriptorProto* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__ServiceDescriptorProto_msg_init(), options, arena, &ptr, len); return ptr; @@ -3039,7 +3432,8 @@ UPB_INLINE void google_protobuf_ServiceDescriptorProto_clear_method(google_proto const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ServiceDescriptorProto_msg_init(), 2); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_MethodDescriptorProto* const* google_protobuf_ServiceDescriptorProto_method(const google_protobuf_ServiceDescriptorProto* msg, size_t* size) { +UPB_INLINE const google_protobuf_MethodDescriptorProto* const* google_protobuf_ServiceDescriptorProto_method(const google_protobuf_ServiceDescriptorProto* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ServiceDescriptorProto_msg_init(), 2); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -3050,7 +3444,10 @@ UPB_INLINE const google_protobuf_MethodDescriptorProto* const* google_protobuf_S return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_ServiceDescriptorProto_method_upb_array(const google_protobuf_ServiceDescriptorProto* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_ServiceDescriptorProto_method_upb_array( + const google_protobuf_ServiceDescriptorProto* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ServiceDescriptorProto_msg_init(), 2); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -3058,7 +3455,9 @@ UPB_INLINE const upb_Array* _google_protobuf_ServiceDescriptorProto_method_upb_a } return arr; } -UPB_INLINE upb_Array* _google_protobuf_ServiceDescriptorProto_method_mutable_upb_array(google_protobuf_ServiceDescriptorProto* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_ServiceDescriptorProto_method_mutable_upb_array( + google_protobuf_ServiceDescriptorProto* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ServiceDescriptorProto_msg_init(), 2); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -3084,11 +3483,12 @@ UPB_INLINE bool google_protobuf_ServiceDescriptorProto_has_options(const google_ return upb_Message_HasBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE void google_protobuf_ServiceDescriptorProto_set_name(google_protobuf_ServiceDescriptorProto *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_ServiceDescriptorProto_set_name(google_protobuf_ServiceDescriptorProto* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ServiceDescriptorProto_msg_init(), 1); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE google_protobuf_MethodDescriptorProto** google_protobuf_ServiceDescriptorProto_mutable_method(google_protobuf_ServiceDescriptorProto* msg, size_t* size) { +UPB_INLINE google_protobuf_MethodDescriptorProto** google_protobuf_ServiceDescriptorProto_mutable_method(google_protobuf_ServiceDescriptorProto* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ServiceDescriptorProto_msg_init(), 2); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -3099,12 +3499,16 @@ UPB_INLINE google_protobuf_MethodDescriptorProto** google_protobuf_ServiceDescri return NULL; } } -UPB_INLINE google_protobuf_MethodDescriptorProto** google_protobuf_ServiceDescriptorProto_resize_method(google_protobuf_ServiceDescriptorProto* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_MethodDescriptorProto** google_protobuf_ServiceDescriptorProto_resize_method(google_protobuf_ServiceDescriptorProto* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ServiceDescriptorProto_msg_init(), 2); - return (google_protobuf_MethodDescriptorProto**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_MethodDescriptorProto**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_MethodDescriptorProto* google_protobuf_ServiceDescriptorProto_add_method(google_protobuf_ServiceDescriptorProto* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_MethodDescriptorProto* google_protobuf_ServiceDescriptorProto_add_method( + google_protobuf_ServiceDescriptorProto* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ServiceDescriptorProto_msg_init(), 2); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -3112,17 +3516,19 @@ UPB_INLINE struct google_protobuf_MethodDescriptorProto* google_protobuf_Service arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_MethodDescriptorProto* sub = (struct google_protobuf_MethodDescriptorProto*)_upb_Message_New(google__protobuf__MethodDescriptorProto_msg_init(), arena); + struct google_protobuf_MethodDescriptorProto* sub = + (struct google_protobuf_MethodDescriptorProto*)_upb_Message_New(google__protobuf__MethodDescriptorProto_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); return sub; } -UPB_INLINE void google_protobuf_ServiceDescriptorProto_set_options(google_protobuf_ServiceDescriptorProto *msg, google_protobuf_ServiceOptions* value) { +UPB_INLINE void google_protobuf_ServiceDescriptorProto_set_options(google_protobuf_ServiceDescriptorProto* msg, google_protobuf_ServiceOptions* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ServiceDescriptorProto_msg_init(), 3); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_ServiceOptions* google_protobuf_ServiceDescriptorProto_mutable_options(google_protobuf_ServiceDescriptorProto* msg, upb_Arena* arena) { +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); if (sub == NULL) { sub = (struct google_protobuf_ServiceOptions*)_upb_Message_New(google__protobuf__ServiceOptions_msg_init(), arena); @@ -3132,37 +3538,39 @@ UPB_INLINE struct google_protobuf_ServiceOptions* google_protobuf_ServiceDescrip } /* google.protobuf.MethodDescriptorProto */ - UPB_INLINE google_protobuf_MethodDescriptorProto* google_protobuf_MethodDescriptorProto_new(upb_Arena* arena) { return (google_protobuf_MethodDescriptorProto*)_upb_Message_New(google__protobuf__MethodDescriptorProto_msg_init(), arena); } -UPB_INLINE google_protobuf_MethodDescriptorProto* google_protobuf_MethodDescriptorProto_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_MethodDescriptorProto* google_protobuf_MethodDescriptorProto_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_MethodDescriptorProto* ret = google_protobuf_MethodDescriptorProto_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__MethodDescriptorProto_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__MethodDescriptorProto_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_MethodDescriptorProto* google_protobuf_MethodDescriptorProto_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_MethodDescriptorProto* google_protobuf_MethodDescriptorProto_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_MethodDescriptorProto* ret = google_protobuf_MethodDescriptorProto_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__MethodDescriptorProto_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__MethodDescriptorProto_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_MethodDescriptorProto_serialize(const google_protobuf_MethodDescriptorProto* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_MethodDescriptorProto_serialize(const google_protobuf_MethodDescriptorProto* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__MethodDescriptorProto_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_MethodDescriptorProto_serialize_ex(const google_protobuf_MethodDescriptorProto* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_MethodDescriptorProto_serialize_ex(const google_protobuf_MethodDescriptorProto* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__MethodDescriptorProto_msg_init(), options, arena, &ptr, len); return ptr; @@ -3264,23 +3672,24 @@ UPB_INLINE bool google_protobuf_MethodDescriptorProto_has_server_streaming(const return upb_Message_HasBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE void google_protobuf_MethodDescriptorProto_set_name(google_protobuf_MethodDescriptorProto *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_MethodDescriptorProto_set_name(google_protobuf_MethodDescriptorProto* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MethodDescriptorProto_msg_init(), 1); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_MethodDescriptorProto_set_input_type(google_protobuf_MethodDescriptorProto *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_MethodDescriptorProto_set_input_type(google_protobuf_MethodDescriptorProto* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MethodDescriptorProto_msg_init(), 2); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_MethodDescriptorProto_set_output_type(google_protobuf_MethodDescriptorProto *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_MethodDescriptorProto_set_output_type(google_protobuf_MethodDescriptorProto* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MethodDescriptorProto_msg_init(), 3); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_MethodDescriptorProto_set_options(google_protobuf_MethodDescriptorProto *msg, google_protobuf_MethodOptions* value) { +UPB_INLINE void google_protobuf_MethodDescriptorProto_set_options(google_protobuf_MethodDescriptorProto* msg, google_protobuf_MethodOptions* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MethodDescriptorProto_msg_init(), 4); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_MethodOptions* google_protobuf_MethodDescriptorProto_mutable_options(google_protobuf_MethodDescriptorProto* msg, upb_Arena* arena) { +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); if (sub == NULL) { sub = (struct google_protobuf_MethodOptions*)_upb_Message_New(google__protobuf__MethodOptions_msg_init(), arena); @@ -3288,47 +3697,49 @@ UPB_INLINE struct google_protobuf_MethodOptions* google_protobuf_MethodDescripto } return sub; } -UPB_INLINE void google_protobuf_MethodDescriptorProto_set_client_streaming(google_protobuf_MethodDescriptorProto *msg, bool value) { +UPB_INLINE void google_protobuf_MethodDescriptorProto_set_client_streaming(google_protobuf_MethodDescriptorProto* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MethodDescriptorProto_msg_init(), 5); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_MethodDescriptorProto_set_server_streaming(google_protobuf_MethodDescriptorProto *msg, bool value) { +UPB_INLINE void google_protobuf_MethodDescriptorProto_set_server_streaming(google_protobuf_MethodDescriptorProto* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MethodDescriptorProto_msg_init(), 6); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } /* google.protobuf.FileOptions */ - UPB_INLINE google_protobuf_FileOptions* google_protobuf_FileOptions_new(upb_Arena* arena) { return (google_protobuf_FileOptions*)_upb_Message_New(google__protobuf__FileOptions_msg_init(), arena); } -UPB_INLINE google_protobuf_FileOptions* google_protobuf_FileOptions_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_FileOptions* google_protobuf_FileOptions_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_FileOptions* ret = google_protobuf_FileOptions_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FileOptions_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FileOptions_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_FileOptions* google_protobuf_FileOptions_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_FileOptions* google_protobuf_FileOptions_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_FileOptions* ret = google_protobuf_FileOptions_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FileOptions_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FileOptions_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_FileOptions_serialize(const google_protobuf_FileOptions* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_FileOptions_serialize(const google_protobuf_FileOptions* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__FileOptions_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_FileOptions_serialize_ex(const google_protobuf_FileOptions* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_FileOptions_serialize_ex(const google_protobuf_FileOptions* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__FileOptions_msg_init(), options, arena, &ptr, len); return ptr; @@ -3657,7 +4068,8 @@ UPB_INLINE void google_protobuf_FileOptions_clear_uninterpreted_option(google_pr const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 999); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_FileOptions_uninterpreted_option(const google_protobuf_FileOptions* msg, size_t* size) { +UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_FileOptions_uninterpreted_option(const google_protobuf_FileOptions* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 999); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -3668,7 +4080,10 @@ UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_Fil return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_FileOptions_uninterpreted_option_upb_array(const google_protobuf_FileOptions* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_FileOptions_uninterpreted_option_upb_array( + const google_protobuf_FileOptions* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 999); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -3676,7 +4091,9 @@ UPB_INLINE const upb_Array* _google_protobuf_FileOptions_uninterpreted_option_up } return arr; } -UPB_INLINE upb_Array* _google_protobuf_FileOptions_uninterpreted_option_mutable_upb_array(google_protobuf_FileOptions* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_FileOptions_uninterpreted_option_mutable_upb_array( + google_protobuf_FileOptions* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -3686,87 +4103,88 @@ UPB_INLINE upb_Array* _google_protobuf_FileOptions_uninterpreted_option_mutable_ return arr; } -UPB_INLINE void google_protobuf_FileOptions_set_java_package(google_protobuf_FileOptions *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_FileOptions_set_java_package(google_protobuf_FileOptions* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 1); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FileOptions_set_java_outer_classname(google_protobuf_FileOptions *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_FileOptions_set_java_outer_classname(google_protobuf_FileOptions* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 8); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FileOptions_set_optimize_for(google_protobuf_FileOptions *msg, int32_t value) { +UPB_INLINE void google_protobuf_FileOptions_set_optimize_for(google_protobuf_FileOptions* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 9); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FileOptions_set_java_multiple_files(google_protobuf_FileOptions *msg, bool value) { +UPB_INLINE void google_protobuf_FileOptions_set_java_multiple_files(google_protobuf_FileOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 10); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FileOptions_set_go_package(google_protobuf_FileOptions *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_FileOptions_set_go_package(google_protobuf_FileOptions* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 11); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FileOptions_set_cc_generic_services(google_protobuf_FileOptions *msg, bool value) { +UPB_INLINE void google_protobuf_FileOptions_set_cc_generic_services(google_protobuf_FileOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 16); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FileOptions_set_java_generic_services(google_protobuf_FileOptions *msg, bool value) { +UPB_INLINE void google_protobuf_FileOptions_set_java_generic_services(google_protobuf_FileOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 17); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FileOptions_set_py_generic_services(google_protobuf_FileOptions *msg, bool value) { +UPB_INLINE void google_protobuf_FileOptions_set_py_generic_services(google_protobuf_FileOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 18); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FileOptions_set_java_generate_equals_and_hash(google_protobuf_FileOptions *msg, bool value) { +UPB_INLINE void google_protobuf_FileOptions_set_java_generate_equals_and_hash(google_protobuf_FileOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 20); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FileOptions_set_deprecated(google_protobuf_FileOptions *msg, bool value) { +UPB_INLINE void google_protobuf_FileOptions_set_deprecated(google_protobuf_FileOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 23); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FileOptions_set_java_string_check_utf8(google_protobuf_FileOptions *msg, bool value) { +UPB_INLINE void google_protobuf_FileOptions_set_java_string_check_utf8(google_protobuf_FileOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 27); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FileOptions_set_cc_enable_arenas(google_protobuf_FileOptions *msg, bool value) { +UPB_INLINE void google_protobuf_FileOptions_set_cc_enable_arenas(google_protobuf_FileOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 31); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FileOptions_set_objc_class_prefix(google_protobuf_FileOptions *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_FileOptions_set_objc_class_prefix(google_protobuf_FileOptions* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 36); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FileOptions_set_csharp_namespace(google_protobuf_FileOptions *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_FileOptions_set_csharp_namespace(google_protobuf_FileOptions* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 37); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FileOptions_set_swift_prefix(google_protobuf_FileOptions *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_FileOptions_set_swift_prefix(google_protobuf_FileOptions* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 39); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FileOptions_set_php_class_prefix(google_protobuf_FileOptions *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_FileOptions_set_php_class_prefix(google_protobuf_FileOptions* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 40); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FileOptions_set_php_namespace(google_protobuf_FileOptions *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_FileOptions_set_php_namespace(google_protobuf_FileOptions* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 41); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FileOptions_set_php_metadata_namespace(google_protobuf_FileOptions *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_FileOptions_set_php_metadata_namespace(google_protobuf_FileOptions* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 44); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FileOptions_set_ruby_package(google_protobuf_FileOptions *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_FileOptions_set_ruby_package(google_protobuf_FileOptions* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 45); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FileOptions_set_features(google_protobuf_FileOptions *msg, google_protobuf_FeatureSet* value) { +UPB_INLINE void google_protobuf_FileOptions_set_features(google_protobuf_FileOptions* msg, google_protobuf_FeatureSet* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 50); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_FileOptions_mutable_features(google_protobuf_FileOptions* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_FileOptions_mutable_features( + google_protobuf_FileOptions* msg, upb_Arena* arena) { struct google_protobuf_FeatureSet* sub = (struct google_protobuf_FeatureSet*)google_protobuf_FileOptions_features(msg); if (sub == NULL) { sub = (struct google_protobuf_FeatureSet*)_upb_Message_New(google__protobuf__FeatureSet_msg_init(), arena); @@ -3774,7 +4192,8 @@ UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_FileOptions_mutabl } return sub; } -UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_FileOptions_mutable_uninterpreted_option(google_protobuf_FileOptions* msg, size_t* size) { +UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_FileOptions_mutable_uninterpreted_option(google_protobuf_FileOptions* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -3785,12 +4204,16 @@ UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_FileOptions_mut return NULL; } } -UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_FileOptions_resize_uninterpreted_option(google_protobuf_FileOptions* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_FileOptions_resize_uninterpreted_option(google_protobuf_FileOptions* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 999); - return (google_protobuf_UninterpretedOption**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_UninterpretedOption**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_FileOptions_add_uninterpreted_option(google_protobuf_FileOptions* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_FileOptions_add_uninterpreted_option( + google_protobuf_FileOptions* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FileOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -3798,7 +4221,8 @@ UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_FileOptio arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_UninterpretedOption* sub = (struct google_protobuf_UninterpretedOption*)_upb_Message_New(google__protobuf__UninterpretedOption_msg_init(), arena); + struct google_protobuf_UninterpretedOption* sub = + (struct google_protobuf_UninterpretedOption*)_upb_Message_New(google__protobuf__UninterpretedOption_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); @@ -3806,37 +4230,39 @@ UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_FileOptio } /* google.protobuf.MessageOptions */ - UPB_INLINE google_protobuf_MessageOptions* google_protobuf_MessageOptions_new(upb_Arena* arena) { return (google_protobuf_MessageOptions*)_upb_Message_New(google__protobuf__MessageOptions_msg_init(), arena); } -UPB_INLINE google_protobuf_MessageOptions* google_protobuf_MessageOptions_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_MessageOptions* google_protobuf_MessageOptions_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_MessageOptions* ret = google_protobuf_MessageOptions_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__MessageOptions_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__MessageOptions_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_MessageOptions* google_protobuf_MessageOptions_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_MessageOptions* google_protobuf_MessageOptions_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_MessageOptions* ret = google_protobuf_MessageOptions_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__MessageOptions_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__MessageOptions_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_MessageOptions_serialize(const google_protobuf_MessageOptions* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_MessageOptions_serialize(const google_protobuf_MessageOptions* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__MessageOptions_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_MessageOptions_serialize_ex(const google_protobuf_MessageOptions* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_MessageOptions_serialize_ex(const google_protobuf_MessageOptions* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__MessageOptions_msg_init(), options, arena, &ptr, len); return ptr; @@ -3941,7 +4367,8 @@ UPB_INLINE void google_protobuf_MessageOptions_clear_uninterpreted_option(google const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MessageOptions_msg_init(), 999); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_MessageOptions_uninterpreted_option(const google_protobuf_MessageOptions* msg, size_t* size) { +UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_MessageOptions_uninterpreted_option(const google_protobuf_MessageOptions* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MessageOptions_msg_init(), 999); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -3952,7 +4379,10 @@ UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_Mes return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_MessageOptions_uninterpreted_option_upb_array(const google_protobuf_MessageOptions* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_MessageOptions_uninterpreted_option_upb_array( + const google_protobuf_MessageOptions* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MessageOptions_msg_init(), 999); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -3960,7 +4390,9 @@ UPB_INLINE const upb_Array* _google_protobuf_MessageOptions_uninterpreted_option } return arr; } -UPB_INLINE upb_Array* _google_protobuf_MessageOptions_uninterpreted_option_mutable_upb_array(google_protobuf_MessageOptions* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_MessageOptions_uninterpreted_option_mutable_upb_array( + google_protobuf_MessageOptions* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MessageOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -3970,31 +4402,32 @@ UPB_INLINE upb_Array* _google_protobuf_MessageOptions_uninterpreted_option_mutab return arr; } -UPB_INLINE void google_protobuf_MessageOptions_set_message_set_wire_format(google_protobuf_MessageOptions *msg, bool value) { +UPB_INLINE void google_protobuf_MessageOptions_set_message_set_wire_format(google_protobuf_MessageOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MessageOptions_msg_init(), 1); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_MessageOptions_set_no_standard_descriptor_accessor(google_protobuf_MessageOptions *msg, bool value) { +UPB_INLINE void google_protobuf_MessageOptions_set_no_standard_descriptor_accessor(google_protobuf_MessageOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MessageOptions_msg_init(), 2); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_MessageOptions_set_deprecated(google_protobuf_MessageOptions *msg, bool value) { +UPB_INLINE void google_protobuf_MessageOptions_set_deprecated(google_protobuf_MessageOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MessageOptions_msg_init(), 3); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_MessageOptions_set_map_entry(google_protobuf_MessageOptions *msg, bool value) { +UPB_INLINE void google_protobuf_MessageOptions_set_map_entry(google_protobuf_MessageOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MessageOptions_msg_init(), 7); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_MessageOptions_set_deprecated_legacy_json_field_conflicts(google_protobuf_MessageOptions *msg, bool value) { +UPB_INLINE void google_protobuf_MessageOptions_set_deprecated_legacy_json_field_conflicts(google_protobuf_MessageOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MessageOptions_msg_init(), 11); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_MessageOptions_set_features(google_protobuf_MessageOptions *msg, google_protobuf_FeatureSet* value) { +UPB_INLINE void google_protobuf_MessageOptions_set_features(google_protobuf_MessageOptions* msg, google_protobuf_FeatureSet* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MessageOptions_msg_init(), 12); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_MessageOptions_mutable_features(google_protobuf_MessageOptions* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_MessageOptions_mutable_features( + google_protobuf_MessageOptions* msg, upb_Arena* arena) { struct google_protobuf_FeatureSet* sub = (struct google_protobuf_FeatureSet*)google_protobuf_MessageOptions_features(msg); if (sub == NULL) { sub = (struct google_protobuf_FeatureSet*)_upb_Message_New(google__protobuf__FeatureSet_msg_init(), arena); @@ -4002,7 +4435,8 @@ UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_MessageOptions_mut } return sub; } -UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_MessageOptions_mutable_uninterpreted_option(google_protobuf_MessageOptions* msg, size_t* size) { +UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_MessageOptions_mutable_uninterpreted_option(google_protobuf_MessageOptions* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MessageOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -4013,12 +4447,16 @@ UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_MessageOptions_ return NULL; } } -UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_MessageOptions_resize_uninterpreted_option(google_protobuf_MessageOptions* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_MessageOptions_resize_uninterpreted_option(google_protobuf_MessageOptions* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MessageOptions_msg_init(), 999); - return (google_protobuf_UninterpretedOption**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_UninterpretedOption**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_MessageOptions_add_uninterpreted_option(google_protobuf_MessageOptions* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_MessageOptions_add_uninterpreted_option( + google_protobuf_MessageOptions* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MessageOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -4026,7 +4464,8 @@ UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_MessageOp arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_UninterpretedOption* sub = (struct google_protobuf_UninterpretedOption*)_upb_Message_New(google__protobuf__UninterpretedOption_msg_init(), arena); + struct google_protobuf_UninterpretedOption* sub = + (struct google_protobuf_UninterpretedOption*)_upb_Message_New(google__protobuf__UninterpretedOption_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); @@ -4034,37 +4473,39 @@ UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_MessageOp } /* google.protobuf.FieldOptions */ - UPB_INLINE google_protobuf_FieldOptions* google_protobuf_FieldOptions_new(upb_Arena* arena) { return (google_protobuf_FieldOptions*)_upb_Message_New(google__protobuf__FieldOptions_msg_init(), arena); } -UPB_INLINE google_protobuf_FieldOptions* google_protobuf_FieldOptions_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_FieldOptions* google_protobuf_FieldOptions_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_FieldOptions* ret = google_protobuf_FieldOptions_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FieldOptions_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FieldOptions_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_FieldOptions* google_protobuf_FieldOptions_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_FieldOptions* google_protobuf_FieldOptions_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_FieldOptions* ret = google_protobuf_FieldOptions_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FieldOptions_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FieldOptions_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_FieldOptions_serialize(const google_protobuf_FieldOptions* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_FieldOptions_serialize(const google_protobuf_FieldOptions* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__FieldOptions_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_FieldOptions_serialize_ex(const google_protobuf_FieldOptions* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_FieldOptions_serialize_ex(const google_protobuf_FieldOptions* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__FieldOptions_msg_init(), options, arena, &ptr, len); return ptr; @@ -4217,7 +4658,8 @@ UPB_INLINE void google_protobuf_FieldOptions_clear_targets(google_protobuf_Field const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 19); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE int32_t const* google_protobuf_FieldOptions_targets(const google_protobuf_FieldOptions* msg, size_t* size) { +UPB_INLINE int32_t const* google_protobuf_FieldOptions_targets(const google_protobuf_FieldOptions* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 19); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -4228,7 +4670,10 @@ UPB_INLINE int32_t const* google_protobuf_FieldOptions_targets(const google_prot return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_FieldOptions_targets_upb_array(const google_protobuf_FieldOptions* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_FieldOptions_targets_upb_array( + const google_protobuf_FieldOptions* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 19); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -4236,7 +4681,9 @@ UPB_INLINE const upb_Array* _google_protobuf_FieldOptions_targets_upb_array(cons } return arr; } -UPB_INLINE upb_Array* _google_protobuf_FieldOptions_targets_mutable_upb_array(google_protobuf_FieldOptions* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_FieldOptions_targets_mutable_upb_array( + google_protobuf_FieldOptions* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 19); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -4249,7 +4696,8 @@ UPB_INLINE void google_protobuf_FieldOptions_clear_edition_defaults(google_proto const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 20); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_FieldOptions_EditionDefault* const* google_protobuf_FieldOptions_edition_defaults(const google_protobuf_FieldOptions* msg, size_t* size) { +UPB_INLINE const google_protobuf_FieldOptions_EditionDefault* const* google_protobuf_FieldOptions_edition_defaults(const google_protobuf_FieldOptions* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 20); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -4260,7 +4708,10 @@ UPB_INLINE const google_protobuf_FieldOptions_EditionDefault* const* google_prot return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_FieldOptions_edition_defaults_upb_array(const google_protobuf_FieldOptions* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_FieldOptions_edition_defaults_upb_array( + const google_protobuf_FieldOptions* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 20); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -4268,7 +4719,9 @@ UPB_INLINE const upb_Array* _google_protobuf_FieldOptions_edition_defaults_upb_a } return arr; } -UPB_INLINE upb_Array* _google_protobuf_FieldOptions_edition_defaults_mutable_upb_array(google_protobuf_FieldOptions* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_FieldOptions_edition_defaults_mutable_upb_array( + google_protobuf_FieldOptions* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 20); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -4313,7 +4766,8 @@ UPB_INLINE void google_protobuf_FieldOptions_clear_uninterpreted_option(google_p const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 999); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_FieldOptions_uninterpreted_option(const google_protobuf_FieldOptions* msg, size_t* size) { +UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_FieldOptions_uninterpreted_option(const google_protobuf_FieldOptions* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 999); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -4324,7 +4778,10 @@ UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_Fie return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_FieldOptions_uninterpreted_option_upb_array(const google_protobuf_FieldOptions* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_FieldOptions_uninterpreted_option_upb_array( + const google_protobuf_FieldOptions* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 999); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -4332,7 +4789,9 @@ UPB_INLINE const upb_Array* _google_protobuf_FieldOptions_uninterpreted_option_u } return arr; } -UPB_INLINE upb_Array* _google_protobuf_FieldOptions_uninterpreted_option_mutable_upb_array(google_protobuf_FieldOptions* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_FieldOptions_uninterpreted_option_mutable_upb_array( + google_protobuf_FieldOptions* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -4342,43 +4801,44 @@ UPB_INLINE upb_Array* _google_protobuf_FieldOptions_uninterpreted_option_mutable return arr; } -UPB_INLINE void google_protobuf_FieldOptions_set_ctype(google_protobuf_FieldOptions *msg, int32_t value) { +UPB_INLINE void google_protobuf_FieldOptions_set_ctype(google_protobuf_FieldOptions* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 1); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FieldOptions_set_packed(google_protobuf_FieldOptions *msg, bool value) { +UPB_INLINE void google_protobuf_FieldOptions_set_packed(google_protobuf_FieldOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 2); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FieldOptions_set_deprecated(google_protobuf_FieldOptions *msg, bool value) { +UPB_INLINE void google_protobuf_FieldOptions_set_deprecated(google_protobuf_FieldOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 3); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FieldOptions_set_lazy(google_protobuf_FieldOptions *msg, bool value) { +UPB_INLINE void google_protobuf_FieldOptions_set_lazy(google_protobuf_FieldOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 5); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FieldOptions_set_jstype(google_protobuf_FieldOptions *msg, int32_t value) { +UPB_INLINE void google_protobuf_FieldOptions_set_jstype(google_protobuf_FieldOptions* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 6); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FieldOptions_set_weak(google_protobuf_FieldOptions *msg, bool value) { +UPB_INLINE void google_protobuf_FieldOptions_set_weak(google_protobuf_FieldOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 10); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FieldOptions_set_unverified_lazy(google_protobuf_FieldOptions *msg, bool value) { +UPB_INLINE void google_protobuf_FieldOptions_set_unverified_lazy(google_protobuf_FieldOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 15); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FieldOptions_set_debug_redact(google_protobuf_FieldOptions *msg, bool value) { +UPB_INLINE void google_protobuf_FieldOptions_set_debug_redact(google_protobuf_FieldOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 16); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FieldOptions_set_retention(google_protobuf_FieldOptions *msg, int32_t value) { +UPB_INLINE void google_protobuf_FieldOptions_set_retention(google_protobuf_FieldOptions* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 17); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE int32_t* google_protobuf_FieldOptions_mutable_targets(google_protobuf_FieldOptions* msg, size_t* size) { +UPB_INLINE int32_t* google_protobuf_FieldOptions_mutable_targets(google_protobuf_FieldOptions* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 19); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -4389,12 +4849,16 @@ UPB_INLINE int32_t* google_protobuf_FieldOptions_mutable_targets(google_protobuf return NULL; } } -UPB_INLINE int32_t* google_protobuf_FieldOptions_resize_targets(google_protobuf_FieldOptions* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE int32_t* google_protobuf_FieldOptions_resize_targets(google_protobuf_FieldOptions* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 19); - return (int32_t*)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (int32_t*)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE bool google_protobuf_FieldOptions_add_targets(google_protobuf_FieldOptions* msg, int32_t val, upb_Arena* arena) { +UPB_INLINE bool google_protobuf_FieldOptions_add_targets(google_protobuf_FieldOptions* msg, int32_t val, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 19); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -4406,7 +4870,8 @@ UPB_INLINE bool google_protobuf_FieldOptions_add_targets(google_protobuf_FieldOp (arr, arr->UPB_PRIVATE(size) - 1, &val, sizeof(val)); return true; } -UPB_INLINE google_protobuf_FieldOptions_EditionDefault** google_protobuf_FieldOptions_mutable_edition_defaults(google_protobuf_FieldOptions* msg, size_t* size) { +UPB_INLINE google_protobuf_FieldOptions_EditionDefault** google_protobuf_FieldOptions_mutable_edition_defaults(google_protobuf_FieldOptions* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 20); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -4417,12 +4882,16 @@ UPB_INLINE google_protobuf_FieldOptions_EditionDefault** google_protobuf_FieldOp return NULL; } } -UPB_INLINE google_protobuf_FieldOptions_EditionDefault** google_protobuf_FieldOptions_resize_edition_defaults(google_protobuf_FieldOptions* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_FieldOptions_EditionDefault** google_protobuf_FieldOptions_resize_edition_defaults(google_protobuf_FieldOptions* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 20); - return (google_protobuf_FieldOptions_EditionDefault**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_FieldOptions_EditionDefault**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_FieldOptions_EditionDefault* google_protobuf_FieldOptions_add_edition_defaults(google_protobuf_FieldOptions* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_FieldOptions_EditionDefault* google_protobuf_FieldOptions_add_edition_defaults( + google_protobuf_FieldOptions* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 20); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -4430,17 +4899,19 @@ UPB_INLINE struct google_protobuf_FieldOptions_EditionDefault* google_protobuf_F arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_FieldOptions_EditionDefault* sub = (struct google_protobuf_FieldOptions_EditionDefault*)_upb_Message_New(google__protobuf__FieldOptions__EditionDefault_msg_init(), arena); + struct google_protobuf_FieldOptions_EditionDefault* sub = + (struct google_protobuf_FieldOptions_EditionDefault*)_upb_Message_New(google__protobuf__FieldOptions__EditionDefault_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); return sub; } -UPB_INLINE void google_protobuf_FieldOptions_set_features(google_protobuf_FieldOptions *msg, google_protobuf_FeatureSet* value) { +UPB_INLINE void google_protobuf_FieldOptions_set_features(google_protobuf_FieldOptions* msg, google_protobuf_FeatureSet* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 21); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_FieldOptions_mutable_features(google_protobuf_FieldOptions* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_FieldOptions_mutable_features( + google_protobuf_FieldOptions* msg, upb_Arena* arena) { struct google_protobuf_FeatureSet* sub = (struct google_protobuf_FeatureSet*)google_protobuf_FieldOptions_features(msg); if (sub == NULL) { sub = (struct google_protobuf_FeatureSet*)_upb_Message_New(google__protobuf__FeatureSet_msg_init(), arena); @@ -4448,11 +4919,12 @@ UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_FieldOptions_mutab } return sub; } -UPB_INLINE void google_protobuf_FieldOptions_set_feature_support(google_protobuf_FieldOptions *msg, google_protobuf_FieldOptions_FeatureSupport* value) { +UPB_INLINE void google_protobuf_FieldOptions_set_feature_support(google_protobuf_FieldOptions* msg, google_protobuf_FieldOptions_FeatureSupport* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 22); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_FieldOptions_FeatureSupport* google_protobuf_FieldOptions_mutable_feature_support(google_protobuf_FieldOptions* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_FieldOptions_FeatureSupport* google_protobuf_FieldOptions_mutable_feature_support( + google_protobuf_FieldOptions* msg, upb_Arena* arena) { struct google_protobuf_FieldOptions_FeatureSupport* sub = (struct google_protobuf_FieldOptions_FeatureSupport*)google_protobuf_FieldOptions_feature_support(msg); if (sub == NULL) { sub = (struct google_protobuf_FieldOptions_FeatureSupport*)_upb_Message_New(google__protobuf__FieldOptions__FeatureSupport_msg_init(), arena); @@ -4460,7 +4932,8 @@ UPB_INLINE struct google_protobuf_FieldOptions_FeatureSupport* google_protobuf_F } return sub; } -UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_FieldOptions_mutable_uninterpreted_option(google_protobuf_FieldOptions* msg, size_t* size) { +UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_FieldOptions_mutable_uninterpreted_option(google_protobuf_FieldOptions* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -4471,12 +4944,16 @@ UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_FieldOptions_mu return NULL; } } -UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_FieldOptions_resize_uninterpreted_option(google_protobuf_FieldOptions* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_FieldOptions_resize_uninterpreted_option(google_protobuf_FieldOptions* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 999); - return (google_protobuf_UninterpretedOption**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_UninterpretedOption**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_FieldOptions_add_uninterpreted_option(google_protobuf_FieldOptions* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_FieldOptions_add_uninterpreted_option( + google_protobuf_FieldOptions* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -4484,7 +4961,8 @@ UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_FieldOpti arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_UninterpretedOption* sub = (struct google_protobuf_UninterpretedOption*)_upb_Message_New(google__protobuf__UninterpretedOption_msg_init(), arena); + struct google_protobuf_UninterpretedOption* sub = + (struct google_protobuf_UninterpretedOption*)_upb_Message_New(google__protobuf__UninterpretedOption_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); @@ -4492,37 +4970,39 @@ UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_FieldOpti } /* google.protobuf.FieldOptions.EditionDefault */ - UPB_INLINE google_protobuf_FieldOptions_EditionDefault* google_protobuf_FieldOptions_EditionDefault_new(upb_Arena* arena) { return (google_protobuf_FieldOptions_EditionDefault*)_upb_Message_New(google__protobuf__FieldOptions__EditionDefault_msg_init(), arena); } -UPB_INLINE google_protobuf_FieldOptions_EditionDefault* google_protobuf_FieldOptions_EditionDefault_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_FieldOptions_EditionDefault* google_protobuf_FieldOptions_EditionDefault_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_FieldOptions_EditionDefault* ret = google_protobuf_FieldOptions_EditionDefault_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FieldOptions__EditionDefault_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FieldOptions__EditionDefault_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_FieldOptions_EditionDefault* google_protobuf_FieldOptions_EditionDefault_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_FieldOptions_EditionDefault* google_protobuf_FieldOptions_EditionDefault_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_FieldOptions_EditionDefault* ret = google_protobuf_FieldOptions_EditionDefault_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FieldOptions__EditionDefault_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FieldOptions__EditionDefault_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_FieldOptions_EditionDefault_serialize(const google_protobuf_FieldOptions_EditionDefault* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_FieldOptions_EditionDefault_serialize(const google_protobuf_FieldOptions_EditionDefault* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__FieldOptions__EditionDefault_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_FieldOptions_EditionDefault_serialize_ex(const google_protobuf_FieldOptions_EditionDefault* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_FieldOptions_EditionDefault_serialize_ex(const google_protobuf_FieldOptions_EditionDefault* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__FieldOptions__EditionDefault_msg_init(), options, arena, &ptr, len); return ptr; @@ -4560,47 +5040,49 @@ UPB_INLINE bool google_protobuf_FieldOptions_EditionDefault_has_edition(const go return upb_Message_HasBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE void google_protobuf_FieldOptions_EditionDefault_set_value(google_protobuf_FieldOptions_EditionDefault *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_FieldOptions_EditionDefault_set_value(google_protobuf_FieldOptions_EditionDefault* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions__EditionDefault_msg_init(), 2); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FieldOptions_EditionDefault_set_edition(google_protobuf_FieldOptions_EditionDefault *msg, int32_t value) { +UPB_INLINE void google_protobuf_FieldOptions_EditionDefault_set_edition(google_protobuf_FieldOptions_EditionDefault* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions__EditionDefault_msg_init(), 3); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } /* google.protobuf.FieldOptions.FeatureSupport */ - UPB_INLINE google_protobuf_FieldOptions_FeatureSupport* google_protobuf_FieldOptions_FeatureSupport_new(upb_Arena* arena) { return (google_protobuf_FieldOptions_FeatureSupport*)_upb_Message_New(google__protobuf__FieldOptions__FeatureSupport_msg_init(), arena); } -UPB_INLINE google_protobuf_FieldOptions_FeatureSupport* google_protobuf_FieldOptions_FeatureSupport_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_FieldOptions_FeatureSupport* google_protobuf_FieldOptions_FeatureSupport_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_FieldOptions_FeatureSupport* ret = google_protobuf_FieldOptions_FeatureSupport_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FieldOptions__FeatureSupport_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FieldOptions__FeatureSupport_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_FieldOptions_FeatureSupport* google_protobuf_FieldOptions_FeatureSupport_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_FieldOptions_FeatureSupport* google_protobuf_FieldOptions_FeatureSupport_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_FieldOptions_FeatureSupport* ret = google_protobuf_FieldOptions_FeatureSupport_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FieldOptions__FeatureSupport_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FieldOptions__FeatureSupport_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_FieldOptions_FeatureSupport_serialize(const google_protobuf_FieldOptions_FeatureSupport* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_FieldOptions_FeatureSupport_serialize(const google_protobuf_FieldOptions_FeatureSupport* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__FieldOptions__FeatureSupport_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_FieldOptions_FeatureSupport_serialize_ex(const google_protobuf_FieldOptions_FeatureSupport* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_FieldOptions_FeatureSupport_serialize_ex(const google_protobuf_FieldOptions_FeatureSupport* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__FieldOptions__FeatureSupport_msg_init(), options, arena, &ptr, len); return ptr; @@ -4686,59 +5168,61 @@ UPB_INLINE bool google_protobuf_FieldOptions_FeatureSupport_has_removal_error(co return upb_Message_HasBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE void google_protobuf_FieldOptions_FeatureSupport_set_edition_introduced(google_protobuf_FieldOptions_FeatureSupport *msg, int32_t value) { +UPB_INLINE void google_protobuf_FieldOptions_FeatureSupport_set_edition_introduced(google_protobuf_FieldOptions_FeatureSupport* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions__FeatureSupport_msg_init(), 1); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FieldOptions_FeatureSupport_set_edition_deprecated(google_protobuf_FieldOptions_FeatureSupport *msg, int32_t value) { +UPB_INLINE void google_protobuf_FieldOptions_FeatureSupport_set_edition_deprecated(google_protobuf_FieldOptions_FeatureSupport* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions__FeatureSupport_msg_init(), 2); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FieldOptions_FeatureSupport_set_deprecation_warning(google_protobuf_FieldOptions_FeatureSupport *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_FieldOptions_FeatureSupport_set_deprecation_warning(google_protobuf_FieldOptions_FeatureSupport* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions__FeatureSupport_msg_init(), 3); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FieldOptions_FeatureSupport_set_edition_removed(google_protobuf_FieldOptions_FeatureSupport *msg, int32_t value) { +UPB_INLINE void google_protobuf_FieldOptions_FeatureSupport_set_edition_removed(google_protobuf_FieldOptions_FeatureSupport* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions__FeatureSupport_msg_init(), 4); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FieldOptions_FeatureSupport_set_removal_error(google_protobuf_FieldOptions_FeatureSupport *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_FieldOptions_FeatureSupport_set_removal_error(google_protobuf_FieldOptions_FeatureSupport* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FieldOptions__FeatureSupport_msg_init(), 5); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } /* google.protobuf.OneofOptions */ - UPB_INLINE google_protobuf_OneofOptions* google_protobuf_OneofOptions_new(upb_Arena* arena) { return (google_protobuf_OneofOptions*)_upb_Message_New(google__protobuf__OneofOptions_msg_init(), arena); } -UPB_INLINE google_protobuf_OneofOptions* google_protobuf_OneofOptions_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_OneofOptions* google_protobuf_OneofOptions_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_OneofOptions* ret = google_protobuf_OneofOptions_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__OneofOptions_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__OneofOptions_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_OneofOptions* google_protobuf_OneofOptions_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_OneofOptions* google_protobuf_OneofOptions_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_OneofOptions* ret = google_protobuf_OneofOptions_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__OneofOptions_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__OneofOptions_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_OneofOptions_serialize(const google_protobuf_OneofOptions* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_OneofOptions_serialize(const google_protobuf_OneofOptions* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__OneofOptions_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_OneofOptions_serialize_ex(const google_protobuf_OneofOptions* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_OneofOptions_serialize_ex(const google_protobuf_OneofOptions* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__OneofOptions_msg_init(), options, arena, &ptr, len); return ptr; @@ -4763,7 +5247,8 @@ UPB_INLINE void google_protobuf_OneofOptions_clear_uninterpreted_option(google_p const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__OneofOptions_msg_init(), 999); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_OneofOptions_uninterpreted_option(const google_protobuf_OneofOptions* msg, size_t* size) { +UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_OneofOptions_uninterpreted_option(const google_protobuf_OneofOptions* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__OneofOptions_msg_init(), 999); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -4774,7 +5259,10 @@ UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_One return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_OneofOptions_uninterpreted_option_upb_array(const google_protobuf_OneofOptions* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_OneofOptions_uninterpreted_option_upb_array( + const google_protobuf_OneofOptions* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__OneofOptions_msg_init(), 999); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -4782,7 +5270,9 @@ UPB_INLINE const upb_Array* _google_protobuf_OneofOptions_uninterpreted_option_u } return arr; } -UPB_INLINE upb_Array* _google_protobuf_OneofOptions_uninterpreted_option_mutable_upb_array(google_protobuf_OneofOptions* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_OneofOptions_uninterpreted_option_mutable_upb_array( + google_protobuf_OneofOptions* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__OneofOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -4792,11 +5282,12 @@ UPB_INLINE upb_Array* _google_protobuf_OneofOptions_uninterpreted_option_mutable return arr; } -UPB_INLINE void google_protobuf_OneofOptions_set_features(google_protobuf_OneofOptions *msg, google_protobuf_FeatureSet* value) { +UPB_INLINE void google_protobuf_OneofOptions_set_features(google_protobuf_OneofOptions* msg, google_protobuf_FeatureSet* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__OneofOptions_msg_init(), 1); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_OneofOptions_mutable_features(google_protobuf_OneofOptions* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_OneofOptions_mutable_features( + google_protobuf_OneofOptions* msg, upb_Arena* arena) { struct google_protobuf_FeatureSet* sub = (struct google_protobuf_FeatureSet*)google_protobuf_OneofOptions_features(msg); if (sub == NULL) { sub = (struct google_protobuf_FeatureSet*)_upb_Message_New(google__protobuf__FeatureSet_msg_init(), arena); @@ -4804,7 +5295,8 @@ UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_OneofOptions_mutab } return sub; } -UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_OneofOptions_mutable_uninterpreted_option(google_protobuf_OneofOptions* msg, size_t* size) { +UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_OneofOptions_mutable_uninterpreted_option(google_protobuf_OneofOptions* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__OneofOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -4815,12 +5307,16 @@ UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_OneofOptions_mu return NULL; } } -UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_OneofOptions_resize_uninterpreted_option(google_protobuf_OneofOptions* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_OneofOptions_resize_uninterpreted_option(google_protobuf_OneofOptions* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__OneofOptions_msg_init(), 999); - return (google_protobuf_UninterpretedOption**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_UninterpretedOption**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_OneofOptions_add_uninterpreted_option(google_protobuf_OneofOptions* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_OneofOptions_add_uninterpreted_option( + google_protobuf_OneofOptions* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__OneofOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -4828,7 +5324,8 @@ UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_OneofOpti arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_UninterpretedOption* sub = (struct google_protobuf_UninterpretedOption*)_upb_Message_New(google__protobuf__UninterpretedOption_msg_init(), arena); + struct google_protobuf_UninterpretedOption* sub = + (struct google_protobuf_UninterpretedOption*)_upb_Message_New(google__protobuf__UninterpretedOption_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); @@ -4836,37 +5333,39 @@ UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_OneofOpti } /* google.protobuf.EnumOptions */ - UPB_INLINE google_protobuf_EnumOptions* google_protobuf_EnumOptions_new(upb_Arena* arena) { return (google_protobuf_EnumOptions*)_upb_Message_New(google__protobuf__EnumOptions_msg_init(), arena); } -UPB_INLINE google_protobuf_EnumOptions* google_protobuf_EnumOptions_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_EnumOptions* google_protobuf_EnumOptions_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_EnumOptions* ret = google_protobuf_EnumOptions_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__EnumOptions_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__EnumOptions_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_EnumOptions* google_protobuf_EnumOptions_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_EnumOptions* google_protobuf_EnumOptions_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_EnumOptions* ret = google_protobuf_EnumOptions_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__EnumOptions_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__EnumOptions_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_EnumOptions_serialize(const google_protobuf_EnumOptions* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_EnumOptions_serialize(const google_protobuf_EnumOptions* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__EnumOptions_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_EnumOptions_serialize_ex(const google_protobuf_EnumOptions* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_EnumOptions_serialize_ex(const google_protobuf_EnumOptions* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__EnumOptions_msg_init(), options, arena, &ptr, len); return ptr; @@ -4939,7 +5438,8 @@ UPB_INLINE void google_protobuf_EnumOptions_clear_uninterpreted_option(google_pr const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumOptions_msg_init(), 999); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_EnumOptions_uninterpreted_option(const google_protobuf_EnumOptions* msg, size_t* size) { +UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_EnumOptions_uninterpreted_option(const google_protobuf_EnumOptions* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumOptions_msg_init(), 999); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -4950,7 +5450,10 @@ UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_Enu return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_EnumOptions_uninterpreted_option_upb_array(const google_protobuf_EnumOptions* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_EnumOptions_uninterpreted_option_upb_array( + const google_protobuf_EnumOptions* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumOptions_msg_init(), 999); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -4958,7 +5461,9 @@ UPB_INLINE const upb_Array* _google_protobuf_EnumOptions_uninterpreted_option_up } return arr; } -UPB_INLINE upb_Array* _google_protobuf_EnumOptions_uninterpreted_option_mutable_upb_array(google_protobuf_EnumOptions* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_EnumOptions_uninterpreted_option_mutable_upb_array( + google_protobuf_EnumOptions* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -4968,23 +5473,24 @@ UPB_INLINE upb_Array* _google_protobuf_EnumOptions_uninterpreted_option_mutable_ return arr; } -UPB_INLINE void google_protobuf_EnumOptions_set_allow_alias(google_protobuf_EnumOptions *msg, bool value) { +UPB_INLINE void google_protobuf_EnumOptions_set_allow_alias(google_protobuf_EnumOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumOptions_msg_init(), 2); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_EnumOptions_set_deprecated(google_protobuf_EnumOptions *msg, bool value) { +UPB_INLINE void google_protobuf_EnumOptions_set_deprecated(google_protobuf_EnumOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumOptions_msg_init(), 3); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_EnumOptions_set_deprecated_legacy_json_field_conflicts(google_protobuf_EnumOptions *msg, bool value) { +UPB_INLINE void google_protobuf_EnumOptions_set_deprecated_legacy_json_field_conflicts(google_protobuf_EnumOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumOptions_msg_init(), 6); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_EnumOptions_set_features(google_protobuf_EnumOptions *msg, google_protobuf_FeatureSet* value) { +UPB_INLINE void google_protobuf_EnumOptions_set_features(google_protobuf_EnumOptions* msg, google_protobuf_FeatureSet* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumOptions_msg_init(), 7); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_EnumOptions_mutable_features(google_protobuf_EnumOptions* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_EnumOptions_mutable_features( + google_protobuf_EnumOptions* msg, upb_Arena* arena) { struct google_protobuf_FeatureSet* sub = (struct google_protobuf_FeatureSet*)google_protobuf_EnumOptions_features(msg); if (sub == NULL) { sub = (struct google_protobuf_FeatureSet*)_upb_Message_New(google__protobuf__FeatureSet_msg_init(), arena); @@ -4992,7 +5498,8 @@ UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_EnumOptions_mutabl } return sub; } -UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_EnumOptions_mutable_uninterpreted_option(google_protobuf_EnumOptions* msg, size_t* size) { +UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_EnumOptions_mutable_uninterpreted_option(google_protobuf_EnumOptions* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -5003,12 +5510,16 @@ UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_EnumOptions_mut return NULL; } } -UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_EnumOptions_resize_uninterpreted_option(google_protobuf_EnumOptions* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_EnumOptions_resize_uninterpreted_option(google_protobuf_EnumOptions* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumOptions_msg_init(), 999); - return (google_protobuf_UninterpretedOption**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_UninterpretedOption**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_EnumOptions_add_uninterpreted_option(google_protobuf_EnumOptions* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_EnumOptions_add_uninterpreted_option( + google_protobuf_EnumOptions* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -5016,7 +5527,8 @@ UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_EnumOptio arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_UninterpretedOption* sub = (struct google_protobuf_UninterpretedOption*)_upb_Message_New(google__protobuf__UninterpretedOption_msg_init(), arena); + struct google_protobuf_UninterpretedOption* sub = + (struct google_protobuf_UninterpretedOption*)_upb_Message_New(google__protobuf__UninterpretedOption_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); @@ -5024,37 +5536,39 @@ UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_EnumOptio } /* google.protobuf.EnumValueOptions */ - UPB_INLINE google_protobuf_EnumValueOptions* google_protobuf_EnumValueOptions_new(upb_Arena* arena) { return (google_protobuf_EnumValueOptions*)_upb_Message_New(google__protobuf__EnumValueOptions_msg_init(), arena); } -UPB_INLINE google_protobuf_EnumValueOptions* google_protobuf_EnumValueOptions_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_EnumValueOptions* google_protobuf_EnumValueOptions_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_EnumValueOptions* ret = google_protobuf_EnumValueOptions_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__EnumValueOptions_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__EnumValueOptions_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_EnumValueOptions* google_protobuf_EnumValueOptions_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_EnumValueOptions* google_protobuf_EnumValueOptions_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_EnumValueOptions* ret = google_protobuf_EnumValueOptions_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__EnumValueOptions_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__EnumValueOptions_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_EnumValueOptions_serialize(const google_protobuf_EnumValueOptions* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_EnumValueOptions_serialize(const google_protobuf_EnumValueOptions* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__EnumValueOptions_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_EnumValueOptions_serialize_ex(const google_protobuf_EnumValueOptions* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_EnumValueOptions_serialize_ex(const google_protobuf_EnumValueOptions* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__EnumValueOptions_msg_init(), options, arena, &ptr, len); return ptr; @@ -5127,7 +5641,8 @@ UPB_INLINE void google_protobuf_EnumValueOptions_clear_uninterpreted_option(goog const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumValueOptions_msg_init(), 999); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_EnumValueOptions_uninterpreted_option(const google_protobuf_EnumValueOptions* msg, size_t* size) { +UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_EnumValueOptions_uninterpreted_option(const google_protobuf_EnumValueOptions* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumValueOptions_msg_init(), 999); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -5138,7 +5653,10 @@ UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_Enu return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_EnumValueOptions_uninterpreted_option_upb_array(const google_protobuf_EnumValueOptions* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_EnumValueOptions_uninterpreted_option_upb_array( + const google_protobuf_EnumValueOptions* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumValueOptions_msg_init(), 999); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -5146,7 +5664,9 @@ UPB_INLINE const upb_Array* _google_protobuf_EnumValueOptions_uninterpreted_opti } return arr; } -UPB_INLINE upb_Array* _google_protobuf_EnumValueOptions_uninterpreted_option_mutable_upb_array(google_protobuf_EnumValueOptions* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_EnumValueOptions_uninterpreted_option_mutable_upb_array( + google_protobuf_EnumValueOptions* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumValueOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -5156,15 +5676,16 @@ UPB_INLINE upb_Array* _google_protobuf_EnumValueOptions_uninterpreted_option_mut return arr; } -UPB_INLINE void google_protobuf_EnumValueOptions_set_deprecated(google_protobuf_EnumValueOptions *msg, bool value) { +UPB_INLINE void google_protobuf_EnumValueOptions_set_deprecated(google_protobuf_EnumValueOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumValueOptions_msg_init(), 1); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_EnumValueOptions_set_features(google_protobuf_EnumValueOptions *msg, google_protobuf_FeatureSet* value) { +UPB_INLINE void google_protobuf_EnumValueOptions_set_features(google_protobuf_EnumValueOptions* msg, google_protobuf_FeatureSet* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumValueOptions_msg_init(), 2); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_EnumValueOptions_mutable_features(google_protobuf_EnumValueOptions* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_EnumValueOptions_mutable_features( + google_protobuf_EnumValueOptions* msg, upb_Arena* arena) { struct google_protobuf_FeatureSet* sub = (struct google_protobuf_FeatureSet*)google_protobuf_EnumValueOptions_features(msg); if (sub == NULL) { sub = (struct google_protobuf_FeatureSet*)_upb_Message_New(google__protobuf__FeatureSet_msg_init(), arena); @@ -5172,15 +5693,16 @@ UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_EnumValueOptions_m } return sub; } -UPB_INLINE void google_protobuf_EnumValueOptions_set_debug_redact(google_protobuf_EnumValueOptions *msg, bool value) { +UPB_INLINE void google_protobuf_EnumValueOptions_set_debug_redact(google_protobuf_EnumValueOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumValueOptions_msg_init(), 3); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_EnumValueOptions_set_feature_support(google_protobuf_EnumValueOptions *msg, google_protobuf_FieldOptions_FeatureSupport* value) { +UPB_INLINE void google_protobuf_EnumValueOptions_set_feature_support(google_protobuf_EnumValueOptions* msg, google_protobuf_FieldOptions_FeatureSupport* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumValueOptions_msg_init(), 4); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_FieldOptions_FeatureSupport* google_protobuf_EnumValueOptions_mutable_feature_support(google_protobuf_EnumValueOptions* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_FieldOptions_FeatureSupport* google_protobuf_EnumValueOptions_mutable_feature_support( + google_protobuf_EnumValueOptions* msg, upb_Arena* arena) { struct google_protobuf_FieldOptions_FeatureSupport* sub = (struct google_protobuf_FieldOptions_FeatureSupport*)google_protobuf_EnumValueOptions_feature_support(msg); if (sub == NULL) { sub = (struct google_protobuf_FieldOptions_FeatureSupport*)_upb_Message_New(google__protobuf__FieldOptions__FeatureSupport_msg_init(), arena); @@ -5188,7 +5710,8 @@ UPB_INLINE struct google_protobuf_FieldOptions_FeatureSupport* google_protobuf_E } return sub; } -UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_EnumValueOptions_mutable_uninterpreted_option(google_protobuf_EnumValueOptions* msg, size_t* size) { +UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_EnumValueOptions_mutable_uninterpreted_option(google_protobuf_EnumValueOptions* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumValueOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -5199,12 +5722,16 @@ UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_EnumValueOption return NULL; } } -UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_EnumValueOptions_resize_uninterpreted_option(google_protobuf_EnumValueOptions* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_EnumValueOptions_resize_uninterpreted_option(google_protobuf_EnumValueOptions* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumValueOptions_msg_init(), 999); - return (google_protobuf_UninterpretedOption**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_UninterpretedOption**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_EnumValueOptions_add_uninterpreted_option(google_protobuf_EnumValueOptions* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_EnumValueOptions_add_uninterpreted_option( + google_protobuf_EnumValueOptions* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__EnumValueOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -5212,7 +5739,8 @@ UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_EnumValue arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_UninterpretedOption* sub = (struct google_protobuf_UninterpretedOption*)_upb_Message_New(google__protobuf__UninterpretedOption_msg_init(), arena); + struct google_protobuf_UninterpretedOption* sub = + (struct google_protobuf_UninterpretedOption*)_upb_Message_New(google__protobuf__UninterpretedOption_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); @@ -5220,37 +5748,39 @@ UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_EnumValue } /* google.protobuf.ServiceOptions */ - UPB_INLINE google_protobuf_ServiceOptions* google_protobuf_ServiceOptions_new(upb_Arena* arena) { return (google_protobuf_ServiceOptions*)_upb_Message_New(google__protobuf__ServiceOptions_msg_init(), arena); } -UPB_INLINE google_protobuf_ServiceOptions* google_protobuf_ServiceOptions_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_ServiceOptions* google_protobuf_ServiceOptions_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_ServiceOptions* ret = google_protobuf_ServiceOptions_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__ServiceOptions_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__ServiceOptions_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_ServiceOptions* google_protobuf_ServiceOptions_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_ServiceOptions* google_protobuf_ServiceOptions_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_ServiceOptions* ret = google_protobuf_ServiceOptions_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__ServiceOptions_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__ServiceOptions_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_ServiceOptions_serialize(const google_protobuf_ServiceOptions* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_ServiceOptions_serialize(const google_protobuf_ServiceOptions* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__ServiceOptions_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_ServiceOptions_serialize_ex(const google_protobuf_ServiceOptions* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_ServiceOptions_serialize_ex(const google_protobuf_ServiceOptions* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__ServiceOptions_msg_init(), options, arena, &ptr, len); return ptr; @@ -5291,7 +5821,8 @@ UPB_INLINE void google_protobuf_ServiceOptions_clear_uninterpreted_option(google const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ServiceOptions_msg_init(), 999); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_ServiceOptions_uninterpreted_option(const google_protobuf_ServiceOptions* msg, size_t* size) { +UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_ServiceOptions_uninterpreted_option(const google_protobuf_ServiceOptions* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ServiceOptions_msg_init(), 999); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -5302,7 +5833,10 @@ UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_Ser return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_ServiceOptions_uninterpreted_option_upb_array(const google_protobuf_ServiceOptions* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_ServiceOptions_uninterpreted_option_upb_array( + const google_protobuf_ServiceOptions* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ServiceOptions_msg_init(), 999); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -5310,7 +5844,9 @@ UPB_INLINE const upb_Array* _google_protobuf_ServiceOptions_uninterpreted_option } return arr; } -UPB_INLINE upb_Array* _google_protobuf_ServiceOptions_uninterpreted_option_mutable_upb_array(google_protobuf_ServiceOptions* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_ServiceOptions_uninterpreted_option_mutable_upb_array( + google_protobuf_ServiceOptions* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ServiceOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -5320,15 +5856,16 @@ UPB_INLINE upb_Array* _google_protobuf_ServiceOptions_uninterpreted_option_mutab return arr; } -UPB_INLINE void google_protobuf_ServiceOptions_set_deprecated(google_protobuf_ServiceOptions *msg, bool value) { +UPB_INLINE void google_protobuf_ServiceOptions_set_deprecated(google_protobuf_ServiceOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ServiceOptions_msg_init(), 33); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_ServiceOptions_set_features(google_protobuf_ServiceOptions *msg, google_protobuf_FeatureSet* value) { +UPB_INLINE void google_protobuf_ServiceOptions_set_features(google_protobuf_ServiceOptions* msg, google_protobuf_FeatureSet* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ServiceOptions_msg_init(), 34); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_ServiceOptions_mutable_features(google_protobuf_ServiceOptions* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_ServiceOptions_mutable_features( + google_protobuf_ServiceOptions* msg, upb_Arena* arena) { struct google_protobuf_FeatureSet* sub = (struct google_protobuf_FeatureSet*)google_protobuf_ServiceOptions_features(msg); if (sub == NULL) { sub = (struct google_protobuf_FeatureSet*)_upb_Message_New(google__protobuf__FeatureSet_msg_init(), arena); @@ -5336,7 +5873,8 @@ UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_ServiceOptions_mut } return sub; } -UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_ServiceOptions_mutable_uninterpreted_option(google_protobuf_ServiceOptions* msg, size_t* size) { +UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_ServiceOptions_mutable_uninterpreted_option(google_protobuf_ServiceOptions* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ServiceOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -5347,12 +5885,16 @@ UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_ServiceOptions_ return NULL; } } -UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_ServiceOptions_resize_uninterpreted_option(google_protobuf_ServiceOptions* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_ServiceOptions_resize_uninterpreted_option(google_protobuf_ServiceOptions* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ServiceOptions_msg_init(), 999); - return (google_protobuf_UninterpretedOption**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_UninterpretedOption**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_ServiceOptions_add_uninterpreted_option(google_protobuf_ServiceOptions* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_ServiceOptions_add_uninterpreted_option( + google_protobuf_ServiceOptions* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__ServiceOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -5360,7 +5902,8 @@ UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_ServiceOp arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_UninterpretedOption* sub = (struct google_protobuf_UninterpretedOption*)_upb_Message_New(google__protobuf__UninterpretedOption_msg_init(), arena); + struct google_protobuf_UninterpretedOption* sub = + (struct google_protobuf_UninterpretedOption*)_upb_Message_New(google__protobuf__UninterpretedOption_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); @@ -5368,37 +5911,39 @@ UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_ServiceOp } /* google.protobuf.MethodOptions */ - UPB_INLINE google_protobuf_MethodOptions* google_protobuf_MethodOptions_new(upb_Arena* arena) { return (google_protobuf_MethodOptions*)_upb_Message_New(google__protobuf__MethodOptions_msg_init(), arena); } -UPB_INLINE google_protobuf_MethodOptions* google_protobuf_MethodOptions_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_MethodOptions* google_protobuf_MethodOptions_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_MethodOptions* ret = google_protobuf_MethodOptions_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__MethodOptions_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__MethodOptions_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_MethodOptions* google_protobuf_MethodOptions_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_MethodOptions* google_protobuf_MethodOptions_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_MethodOptions* ret = google_protobuf_MethodOptions_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__MethodOptions_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__MethodOptions_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_MethodOptions_serialize(const google_protobuf_MethodOptions* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_MethodOptions_serialize(const google_protobuf_MethodOptions* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__MethodOptions_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_MethodOptions_serialize_ex(const google_protobuf_MethodOptions* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_MethodOptions_serialize_ex(const google_protobuf_MethodOptions* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__MethodOptions_msg_init(), options, arena, &ptr, len); return ptr; @@ -5455,7 +6000,8 @@ UPB_INLINE void google_protobuf_MethodOptions_clear_uninterpreted_option(google_ const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MethodOptions_msg_init(), 999); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_MethodOptions_uninterpreted_option(const google_protobuf_MethodOptions* msg, size_t* size) { +UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_MethodOptions_uninterpreted_option(const google_protobuf_MethodOptions* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MethodOptions_msg_init(), 999); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -5466,7 +6012,10 @@ UPB_INLINE const google_protobuf_UninterpretedOption* const* google_protobuf_Met return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_MethodOptions_uninterpreted_option_upb_array(const google_protobuf_MethodOptions* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_MethodOptions_uninterpreted_option_upb_array( + const google_protobuf_MethodOptions* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MethodOptions_msg_init(), 999); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -5474,7 +6023,9 @@ UPB_INLINE const upb_Array* _google_protobuf_MethodOptions_uninterpreted_option_ } return arr; } -UPB_INLINE upb_Array* _google_protobuf_MethodOptions_uninterpreted_option_mutable_upb_array(google_protobuf_MethodOptions* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_MethodOptions_uninterpreted_option_mutable_upb_array( + google_protobuf_MethodOptions* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MethodOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -5484,19 +6035,20 @@ UPB_INLINE upb_Array* _google_protobuf_MethodOptions_uninterpreted_option_mutabl return arr; } -UPB_INLINE void google_protobuf_MethodOptions_set_deprecated(google_protobuf_MethodOptions *msg, bool value) { +UPB_INLINE void google_protobuf_MethodOptions_set_deprecated(google_protobuf_MethodOptions* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MethodOptions_msg_init(), 33); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_MethodOptions_set_idempotency_level(google_protobuf_MethodOptions *msg, int32_t value) { +UPB_INLINE void google_protobuf_MethodOptions_set_idempotency_level(google_protobuf_MethodOptions* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MethodOptions_msg_init(), 34); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_MethodOptions_set_features(google_protobuf_MethodOptions *msg, google_protobuf_FeatureSet* value) { +UPB_INLINE void google_protobuf_MethodOptions_set_features(google_protobuf_MethodOptions* msg, google_protobuf_FeatureSet* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MethodOptions_msg_init(), 35); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_MethodOptions_mutable_features(google_protobuf_MethodOptions* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_MethodOptions_mutable_features( + google_protobuf_MethodOptions* msg, upb_Arena* arena) { struct google_protobuf_FeatureSet* sub = (struct google_protobuf_FeatureSet*)google_protobuf_MethodOptions_features(msg); if (sub == NULL) { sub = (struct google_protobuf_FeatureSet*)_upb_Message_New(google__protobuf__FeatureSet_msg_init(), arena); @@ -5504,7 +6056,8 @@ UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_MethodOptions_muta } return sub; } -UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_MethodOptions_mutable_uninterpreted_option(google_protobuf_MethodOptions* msg, size_t* size) { +UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_MethodOptions_mutable_uninterpreted_option(google_protobuf_MethodOptions* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MethodOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -5515,12 +6068,16 @@ UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_MethodOptions_m return NULL; } } -UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_MethodOptions_resize_uninterpreted_option(google_protobuf_MethodOptions* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_UninterpretedOption** google_protobuf_MethodOptions_resize_uninterpreted_option(google_protobuf_MethodOptions* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MethodOptions_msg_init(), 999); - return (google_protobuf_UninterpretedOption**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_UninterpretedOption**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_MethodOptions_add_uninterpreted_option(google_protobuf_MethodOptions* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_MethodOptions_add_uninterpreted_option( + google_protobuf_MethodOptions* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__MethodOptions_msg_init(), 999); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -5528,7 +6085,8 @@ UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_MethodOpt arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_UninterpretedOption* sub = (struct google_protobuf_UninterpretedOption*)_upb_Message_New(google__protobuf__UninterpretedOption_msg_init(), arena); + struct google_protobuf_UninterpretedOption* sub = + (struct google_protobuf_UninterpretedOption*)_upb_Message_New(google__protobuf__UninterpretedOption_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); @@ -5536,37 +6094,39 @@ UPB_INLINE struct google_protobuf_UninterpretedOption* google_protobuf_MethodOpt } /* google.protobuf.UninterpretedOption */ - UPB_INLINE google_protobuf_UninterpretedOption* google_protobuf_UninterpretedOption_new(upb_Arena* arena) { return (google_protobuf_UninterpretedOption*)_upb_Message_New(google__protobuf__UninterpretedOption_msg_init(), arena); } -UPB_INLINE google_protobuf_UninterpretedOption* google_protobuf_UninterpretedOption_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_UninterpretedOption* google_protobuf_UninterpretedOption_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_UninterpretedOption* ret = google_protobuf_UninterpretedOption_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__UninterpretedOption_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__UninterpretedOption_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_UninterpretedOption* google_protobuf_UninterpretedOption_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_UninterpretedOption* google_protobuf_UninterpretedOption_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_UninterpretedOption* ret = google_protobuf_UninterpretedOption_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__UninterpretedOption_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__UninterpretedOption_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_UninterpretedOption_serialize(const google_protobuf_UninterpretedOption* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_UninterpretedOption_serialize(const google_protobuf_UninterpretedOption* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__UninterpretedOption_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_UninterpretedOption_serialize_ex(const google_protobuf_UninterpretedOption* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_UninterpretedOption_serialize_ex(const google_protobuf_UninterpretedOption* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__UninterpretedOption_msg_init(), options, arena, &ptr, len); return ptr; @@ -5575,7 +6135,8 @@ UPB_INLINE void google_protobuf_UninterpretedOption_clear_name(google_protobuf_U const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__UninterpretedOption_msg_init(), 2); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_UninterpretedOption_NamePart* const* google_protobuf_UninterpretedOption_name(const google_protobuf_UninterpretedOption* msg, size_t* size) { +UPB_INLINE const google_protobuf_UninterpretedOption_NamePart* const* google_protobuf_UninterpretedOption_name(const google_protobuf_UninterpretedOption* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__UninterpretedOption_msg_init(), 2); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -5586,7 +6147,10 @@ UPB_INLINE const google_protobuf_UninterpretedOption_NamePart* const* google_pro return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_UninterpretedOption_name_upb_array(const google_protobuf_UninterpretedOption* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_UninterpretedOption_name_upb_array( + const google_protobuf_UninterpretedOption* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__UninterpretedOption_msg_init(), 2); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -5594,7 +6158,9 @@ UPB_INLINE const upb_Array* _google_protobuf_UninterpretedOption_name_upb_array( } return arr; } -UPB_INLINE upb_Array* _google_protobuf_UninterpretedOption_name_mutable_upb_array(google_protobuf_UninterpretedOption* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_UninterpretedOption_name_mutable_upb_array( + google_protobuf_UninterpretedOption* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__UninterpretedOption_msg_init(), 2); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -5700,7 +6266,8 @@ UPB_INLINE bool google_protobuf_UninterpretedOption_has_aggregate_value(const go return upb_Message_HasBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE google_protobuf_UninterpretedOption_NamePart** google_protobuf_UninterpretedOption_mutable_name(google_protobuf_UninterpretedOption* msg, size_t* size) { +UPB_INLINE google_protobuf_UninterpretedOption_NamePart** google_protobuf_UninterpretedOption_mutable_name(google_protobuf_UninterpretedOption* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__UninterpretedOption_msg_init(), 2); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -5711,12 +6278,16 @@ UPB_INLINE google_protobuf_UninterpretedOption_NamePart** google_protobuf_Uninte return NULL; } } -UPB_INLINE google_protobuf_UninterpretedOption_NamePart** google_protobuf_UninterpretedOption_resize_name(google_protobuf_UninterpretedOption* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_UninterpretedOption_NamePart** google_protobuf_UninterpretedOption_resize_name(google_protobuf_UninterpretedOption* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__UninterpretedOption_msg_init(), 2); - return (google_protobuf_UninterpretedOption_NamePart**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_UninterpretedOption_NamePart**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_UninterpretedOption_NamePart* google_protobuf_UninterpretedOption_add_name(google_protobuf_UninterpretedOption* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_UninterpretedOption_NamePart* google_protobuf_UninterpretedOption_add_name( + google_protobuf_UninterpretedOption* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__UninterpretedOption_msg_init(), 2); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -5724,69 +6295,72 @@ UPB_INLINE struct google_protobuf_UninterpretedOption_NamePart* google_protobuf_ arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_UninterpretedOption_NamePart* sub = (struct google_protobuf_UninterpretedOption_NamePart*)_upb_Message_New(google__protobuf__UninterpretedOption__NamePart_msg_init(), arena); + struct google_protobuf_UninterpretedOption_NamePart* sub = + (struct google_protobuf_UninterpretedOption_NamePart*)_upb_Message_New(google__protobuf__UninterpretedOption__NamePart_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); return sub; } -UPB_INLINE void google_protobuf_UninterpretedOption_set_identifier_value(google_protobuf_UninterpretedOption *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_UninterpretedOption_set_identifier_value(google_protobuf_UninterpretedOption* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__UninterpretedOption_msg_init(), 3); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_UninterpretedOption_set_positive_int_value(google_protobuf_UninterpretedOption *msg, uint64_t value) { +UPB_INLINE void google_protobuf_UninterpretedOption_set_positive_int_value(google_protobuf_UninterpretedOption* msg, uint64_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__UninterpretedOption_msg_init(), 4); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_UninterpretedOption_set_negative_int_value(google_protobuf_UninterpretedOption *msg, int64_t value) { +UPB_INLINE void google_protobuf_UninterpretedOption_set_negative_int_value(google_protobuf_UninterpretedOption* msg, int64_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__UninterpretedOption_msg_init(), 5); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_UninterpretedOption_set_double_value(google_protobuf_UninterpretedOption *msg, double value) { +UPB_INLINE void google_protobuf_UninterpretedOption_set_double_value(google_protobuf_UninterpretedOption* msg, double value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__UninterpretedOption_msg_init(), 6); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_UninterpretedOption_set_string_value(google_protobuf_UninterpretedOption *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_UninterpretedOption_set_string_value(google_protobuf_UninterpretedOption* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__UninterpretedOption_msg_init(), 7); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_UninterpretedOption_set_aggregate_value(google_protobuf_UninterpretedOption *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_UninterpretedOption_set_aggregate_value(google_protobuf_UninterpretedOption* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__UninterpretedOption_msg_init(), 8); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } /* google.protobuf.UninterpretedOption.NamePart */ - UPB_INLINE google_protobuf_UninterpretedOption_NamePart* google_protobuf_UninterpretedOption_NamePart_new(upb_Arena* arena) { return (google_protobuf_UninterpretedOption_NamePart*)_upb_Message_New(google__protobuf__UninterpretedOption__NamePart_msg_init(), arena); } -UPB_INLINE google_protobuf_UninterpretedOption_NamePart* google_protobuf_UninterpretedOption_NamePart_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_UninterpretedOption_NamePart* google_protobuf_UninterpretedOption_NamePart_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_UninterpretedOption_NamePart* ret = google_protobuf_UninterpretedOption_NamePart_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__UninterpretedOption__NamePart_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__UninterpretedOption__NamePart_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_UninterpretedOption_NamePart* google_protobuf_UninterpretedOption_NamePart_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_UninterpretedOption_NamePart* google_protobuf_UninterpretedOption_NamePart_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_UninterpretedOption_NamePart* ret = google_protobuf_UninterpretedOption_NamePart_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__UninterpretedOption__NamePart_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__UninterpretedOption__NamePart_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_UninterpretedOption_NamePart_serialize(const google_protobuf_UninterpretedOption_NamePart* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_UninterpretedOption_NamePart_serialize(const google_protobuf_UninterpretedOption_NamePart* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__UninterpretedOption__NamePart_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_UninterpretedOption_NamePart_serialize_ex(const google_protobuf_UninterpretedOption_NamePart* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_UninterpretedOption_NamePart_serialize_ex(const google_protobuf_UninterpretedOption_NamePart* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__UninterpretedOption__NamePart_msg_init(), options, arena, &ptr, len); return ptr; @@ -5824,47 +6398,49 @@ UPB_INLINE bool google_protobuf_UninterpretedOption_NamePart_has_is_extension(co return upb_Message_HasBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE void google_protobuf_UninterpretedOption_NamePart_set_name_part(google_protobuf_UninterpretedOption_NamePart *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_UninterpretedOption_NamePart_set_name_part(google_protobuf_UninterpretedOption_NamePart* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__UninterpretedOption__NamePart_msg_init(), 1); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_UninterpretedOption_NamePart_set_is_extension(google_protobuf_UninterpretedOption_NamePart *msg, bool value) { +UPB_INLINE void google_protobuf_UninterpretedOption_NamePart_set_is_extension(google_protobuf_UninterpretedOption_NamePart* msg, bool value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__UninterpretedOption__NamePart_msg_init(), 2); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } /* google.protobuf.FeatureSet */ - UPB_INLINE google_protobuf_FeatureSet* google_protobuf_FeatureSet_new(upb_Arena* arena) { return (google_protobuf_FeatureSet*)_upb_Message_New(google__protobuf__FeatureSet_msg_init(), arena); } -UPB_INLINE google_protobuf_FeatureSet* google_protobuf_FeatureSet_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_FeatureSet* google_protobuf_FeatureSet_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_FeatureSet* ret = google_protobuf_FeatureSet_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FeatureSet_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FeatureSet_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_FeatureSet* google_protobuf_FeatureSet_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_FeatureSet* google_protobuf_FeatureSet_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_FeatureSet* ret = google_protobuf_FeatureSet_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FeatureSet_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FeatureSet_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_FeatureSet_serialize(const google_protobuf_FeatureSet* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_FeatureSet_serialize(const google_protobuf_FeatureSet* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__FeatureSet_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_FeatureSet_serialize_ex(const google_protobuf_FeatureSet* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_FeatureSet_serialize_ex(const google_protobuf_FeatureSet* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__FeatureSet_msg_init(), options, arena, &ptr, len); return ptr; @@ -5998,71 +6574,73 @@ UPB_INLINE bool google_protobuf_FeatureSet_has_default_symbol_visibility(const g return upb_Message_HasBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE void google_protobuf_FeatureSet_set_field_presence(google_protobuf_FeatureSet *msg, int32_t value) { +UPB_INLINE void google_protobuf_FeatureSet_set_field_presence(google_protobuf_FeatureSet* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FeatureSet_msg_init(), 1); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FeatureSet_set_enum_type(google_protobuf_FeatureSet *msg, int32_t value) { +UPB_INLINE void google_protobuf_FeatureSet_set_enum_type(google_protobuf_FeatureSet* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FeatureSet_msg_init(), 2); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FeatureSet_set_repeated_field_encoding(google_protobuf_FeatureSet *msg, int32_t value) { +UPB_INLINE void google_protobuf_FeatureSet_set_repeated_field_encoding(google_protobuf_FeatureSet* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FeatureSet_msg_init(), 3); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FeatureSet_set_utf8_validation(google_protobuf_FeatureSet *msg, int32_t value) { +UPB_INLINE void google_protobuf_FeatureSet_set_utf8_validation(google_protobuf_FeatureSet* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FeatureSet_msg_init(), 4); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FeatureSet_set_message_encoding(google_protobuf_FeatureSet *msg, int32_t value) { +UPB_INLINE void google_protobuf_FeatureSet_set_message_encoding(google_protobuf_FeatureSet* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FeatureSet_msg_init(), 5); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FeatureSet_set_json_format(google_protobuf_FeatureSet *msg, int32_t value) { +UPB_INLINE void google_protobuf_FeatureSet_set_json_format(google_protobuf_FeatureSet* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FeatureSet_msg_init(), 6); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FeatureSet_set_enforce_naming_style(google_protobuf_FeatureSet *msg, int32_t value) { +UPB_INLINE void google_protobuf_FeatureSet_set_enforce_naming_style(google_protobuf_FeatureSet* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FeatureSet_msg_init(), 7); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FeatureSet_set_default_symbol_visibility(google_protobuf_FeatureSet *msg, int32_t value) { +UPB_INLINE void google_protobuf_FeatureSet_set_default_symbol_visibility(google_protobuf_FeatureSet* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FeatureSet_msg_init(), 8); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } /* google.protobuf.FeatureSet.VisibilityFeature */ - UPB_INLINE google_protobuf_FeatureSet_VisibilityFeature* google_protobuf_FeatureSet_VisibilityFeature_new(upb_Arena* arena) { return (google_protobuf_FeatureSet_VisibilityFeature*)_upb_Message_New(google__protobuf__FeatureSet__VisibilityFeature_msg_init(), arena); } -UPB_INLINE google_protobuf_FeatureSet_VisibilityFeature* google_protobuf_FeatureSet_VisibilityFeature_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_FeatureSet_VisibilityFeature* google_protobuf_FeatureSet_VisibilityFeature_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_FeatureSet_VisibilityFeature* ret = google_protobuf_FeatureSet_VisibilityFeature_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FeatureSet__VisibilityFeature_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FeatureSet__VisibilityFeature_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_FeatureSet_VisibilityFeature* google_protobuf_FeatureSet_VisibilityFeature_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_FeatureSet_VisibilityFeature* google_protobuf_FeatureSet_VisibilityFeature_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_FeatureSet_VisibilityFeature* ret = google_protobuf_FeatureSet_VisibilityFeature_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FeatureSet__VisibilityFeature_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FeatureSet__VisibilityFeature_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_FeatureSet_VisibilityFeature_serialize(const google_protobuf_FeatureSet_VisibilityFeature* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_FeatureSet_VisibilityFeature_serialize(const google_protobuf_FeatureSet_VisibilityFeature* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__FeatureSet__VisibilityFeature_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_FeatureSet_VisibilityFeature_serialize_ex(const google_protobuf_FeatureSet_VisibilityFeature* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_FeatureSet_VisibilityFeature_serialize_ex(const google_protobuf_FeatureSet_VisibilityFeature* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__FeatureSet__VisibilityFeature_msg_init(), options, arena, &ptr, len); return ptr; @@ -6070,37 +6648,39 @@ UPB_INLINE char* google_protobuf_FeatureSet_VisibilityFeature_serialize_ex(const /* google.protobuf.FeatureSetDefaults */ - UPB_INLINE google_protobuf_FeatureSetDefaults* google_protobuf_FeatureSetDefaults_new(upb_Arena* arena) { return (google_protobuf_FeatureSetDefaults*)_upb_Message_New(google__protobuf__FeatureSetDefaults_msg_init(), arena); } -UPB_INLINE google_protobuf_FeatureSetDefaults* google_protobuf_FeatureSetDefaults_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_FeatureSetDefaults* google_protobuf_FeatureSetDefaults_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_FeatureSetDefaults* ret = google_protobuf_FeatureSetDefaults_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FeatureSetDefaults_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FeatureSetDefaults_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_FeatureSetDefaults* google_protobuf_FeatureSetDefaults_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_FeatureSetDefaults* google_protobuf_FeatureSetDefaults_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_FeatureSetDefaults* ret = google_protobuf_FeatureSetDefaults_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FeatureSetDefaults_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FeatureSetDefaults_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_FeatureSetDefaults_serialize(const google_protobuf_FeatureSetDefaults* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_FeatureSetDefaults_serialize(const google_protobuf_FeatureSetDefaults* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__FeatureSetDefaults_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_FeatureSetDefaults_serialize_ex(const google_protobuf_FeatureSetDefaults* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_FeatureSetDefaults_serialize_ex(const google_protobuf_FeatureSetDefaults* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__FeatureSetDefaults_msg_init(), options, arena, &ptr, len); return ptr; @@ -6109,7 +6689,8 @@ UPB_INLINE void google_protobuf_FeatureSetDefaults_clear_defaults(google_protobu const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FeatureSetDefaults_msg_init(), 1); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* const* google_protobuf_FeatureSetDefaults_defaults(const google_protobuf_FeatureSetDefaults* msg, size_t* size) { +UPB_INLINE const google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* const* google_protobuf_FeatureSetDefaults_defaults(const google_protobuf_FeatureSetDefaults* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FeatureSetDefaults_msg_init(), 1); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -6120,7 +6701,10 @@ UPB_INLINE const google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* co return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_FeatureSetDefaults_defaults_upb_array(const google_protobuf_FeatureSetDefaults* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_FeatureSetDefaults_defaults_upb_array( + const google_protobuf_FeatureSetDefaults* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FeatureSetDefaults_msg_init(), 1); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -6128,7 +6712,9 @@ UPB_INLINE const upb_Array* _google_protobuf_FeatureSetDefaults_defaults_upb_arr } return arr; } -UPB_INLINE upb_Array* _google_protobuf_FeatureSetDefaults_defaults_mutable_upb_array(google_protobuf_FeatureSetDefaults* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_FeatureSetDefaults_defaults_mutable_upb_array( + google_protobuf_FeatureSetDefaults* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FeatureSetDefaults_msg_init(), 1); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -6170,7 +6756,8 @@ UPB_INLINE bool google_protobuf_FeatureSetDefaults_has_maximum_edition(const goo return upb_Message_HasBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault** google_protobuf_FeatureSetDefaults_mutable_defaults(google_protobuf_FeatureSetDefaults* msg, size_t* size) { +UPB_INLINE google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault** google_protobuf_FeatureSetDefaults_mutable_defaults(google_protobuf_FeatureSetDefaults* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FeatureSetDefaults_msg_init(), 1); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -6181,12 +6768,16 @@ UPB_INLINE google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault** google_ return NULL; } } -UPB_INLINE google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault** google_protobuf_FeatureSetDefaults_resize_defaults(google_protobuf_FeatureSetDefaults* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault** google_protobuf_FeatureSetDefaults_resize_defaults(google_protobuf_FeatureSetDefaults* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FeatureSetDefaults_msg_init(), 1); - return (google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* google_protobuf_FeatureSetDefaults_add_defaults(google_protobuf_FeatureSetDefaults* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* google_protobuf_FeatureSetDefaults_add_defaults( + google_protobuf_FeatureSetDefaults* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FeatureSetDefaults_msg_init(), 1); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -6194,53 +6785,56 @@ UPB_INLINE struct google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* g arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* sub = (struct google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault*)_upb_Message_New(google__protobuf__FeatureSetDefaults__FeatureSetEditionDefault_msg_init(), arena); + struct google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* sub = + (struct google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault*)_upb_Message_New(google__protobuf__FeatureSetDefaults__FeatureSetEditionDefault_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); return sub; } -UPB_INLINE void google_protobuf_FeatureSetDefaults_set_minimum_edition(google_protobuf_FeatureSetDefaults *msg, int32_t value) { +UPB_INLINE void google_protobuf_FeatureSetDefaults_set_minimum_edition(google_protobuf_FeatureSetDefaults* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FeatureSetDefaults_msg_init(), 4); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FeatureSetDefaults_set_maximum_edition(google_protobuf_FeatureSetDefaults *msg, int32_t value) { +UPB_INLINE void google_protobuf_FeatureSetDefaults_set_maximum_edition(google_protobuf_FeatureSetDefaults* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FeatureSetDefaults_msg_init(), 5); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } /* google.protobuf.FeatureSetDefaults.FeatureSetEditionDefault */ - UPB_INLINE google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault_new(upb_Arena* arena) { return (google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault*)_upb_Message_New(google__protobuf__FeatureSetDefaults__FeatureSetEditionDefault_msg_init(), arena); } -UPB_INLINE google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* ret = google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FeatureSetDefaults__FeatureSetEditionDefault_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FeatureSetDefaults__FeatureSetEditionDefault_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* ret = google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FeatureSetDefaults__FeatureSetEditionDefault_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__FeatureSetDefaults__FeatureSetEditionDefault_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault_serialize(const google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault_serialize(const google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__FeatureSetDefaults__FeatureSetEditionDefault_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault_serialize_ex(const google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault_serialize_ex(const google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__FeatureSetDefaults__FeatureSetEditionDefault_msg_init(), options, arena, &ptr, len); return ptr; @@ -6294,15 +6888,16 @@ UPB_INLINE bool google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault_has_ return upb_Message_HasBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE void google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault_set_edition(google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault *msg, int32_t value) { +UPB_INLINE void google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault_set_edition(google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FeatureSetDefaults__FeatureSetEditionDefault_msg_init(), 3); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault_set_overridable_features(google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault *msg, google_protobuf_FeatureSet* value) { +UPB_INLINE void google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault_set_overridable_features(google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* msg, google_protobuf_FeatureSet* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FeatureSetDefaults__FeatureSetEditionDefault_msg_init(), 4); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault_mutable_overridable_features(google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault_mutable_overridable_features( + google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* msg, upb_Arena* arena) { struct google_protobuf_FeatureSet* sub = (struct google_protobuf_FeatureSet*)google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault_overridable_features(msg); if (sub == NULL) { sub = (struct google_protobuf_FeatureSet*)_upb_Message_New(google__protobuf__FeatureSet_msg_init(), arena); @@ -6310,11 +6905,12 @@ UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_FeatureSetDefaults } return sub; } -UPB_INLINE void google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault_set_fixed_features(google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault *msg, google_protobuf_FeatureSet* value) { +UPB_INLINE void google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault_set_fixed_features(google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* msg, google_protobuf_FeatureSet* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__FeatureSetDefaults__FeatureSetEditionDefault_msg_init(), 5); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault_mutable_fixed_features(google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault_mutable_fixed_features( + google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault* msg, upb_Arena* arena) { struct google_protobuf_FeatureSet* sub = (struct google_protobuf_FeatureSet*)google_protobuf_FeatureSetDefaults_FeatureSetEditionDefault_fixed_features(msg); if (sub == NULL) { sub = (struct google_protobuf_FeatureSet*)_upb_Message_New(google__protobuf__FeatureSet_msg_init(), arena); @@ -6324,37 +6920,39 @@ UPB_INLINE struct google_protobuf_FeatureSet* google_protobuf_FeatureSetDefaults } /* google.protobuf.SourceCodeInfo */ - UPB_INLINE google_protobuf_SourceCodeInfo* google_protobuf_SourceCodeInfo_new(upb_Arena* arena) { return (google_protobuf_SourceCodeInfo*)_upb_Message_New(google__protobuf__SourceCodeInfo_msg_init(), arena); } -UPB_INLINE google_protobuf_SourceCodeInfo* google_protobuf_SourceCodeInfo_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_SourceCodeInfo* google_protobuf_SourceCodeInfo_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_SourceCodeInfo* ret = google_protobuf_SourceCodeInfo_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__SourceCodeInfo_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__SourceCodeInfo_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_SourceCodeInfo* google_protobuf_SourceCodeInfo_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_SourceCodeInfo* google_protobuf_SourceCodeInfo_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_SourceCodeInfo* ret = google_protobuf_SourceCodeInfo_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__SourceCodeInfo_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__SourceCodeInfo_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_SourceCodeInfo_serialize(const google_protobuf_SourceCodeInfo* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_SourceCodeInfo_serialize(const google_protobuf_SourceCodeInfo* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__SourceCodeInfo_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_SourceCodeInfo_serialize_ex(const google_protobuf_SourceCodeInfo* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_SourceCodeInfo_serialize_ex(const google_protobuf_SourceCodeInfo* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__SourceCodeInfo_msg_init(), options, arena, &ptr, len); return ptr; @@ -6363,7 +6961,8 @@ UPB_INLINE void google_protobuf_SourceCodeInfo_clear_location(google_protobuf_So const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo_msg_init(), 1); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_SourceCodeInfo_Location* const* google_protobuf_SourceCodeInfo_location(const google_protobuf_SourceCodeInfo* msg, size_t* size) { +UPB_INLINE const google_protobuf_SourceCodeInfo_Location* const* google_protobuf_SourceCodeInfo_location(const google_protobuf_SourceCodeInfo* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo_msg_init(), 1); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -6374,7 +6973,10 @@ UPB_INLINE const google_protobuf_SourceCodeInfo_Location* const* google_protobuf return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_SourceCodeInfo_location_upb_array(const google_protobuf_SourceCodeInfo* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_SourceCodeInfo_location_upb_array( + const google_protobuf_SourceCodeInfo* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo_msg_init(), 1); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -6382,7 +6984,9 @@ UPB_INLINE const upb_Array* _google_protobuf_SourceCodeInfo_location_upb_array(c } return arr; } -UPB_INLINE upb_Array* _google_protobuf_SourceCodeInfo_location_mutable_upb_array(google_protobuf_SourceCodeInfo* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_SourceCodeInfo_location_mutable_upb_array( + google_protobuf_SourceCodeInfo* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo_msg_init(), 1); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -6392,7 +6996,8 @@ UPB_INLINE upb_Array* _google_protobuf_SourceCodeInfo_location_mutable_upb_array return arr; } -UPB_INLINE google_protobuf_SourceCodeInfo_Location** google_protobuf_SourceCodeInfo_mutable_location(google_protobuf_SourceCodeInfo* msg, size_t* size) { +UPB_INLINE google_protobuf_SourceCodeInfo_Location** google_protobuf_SourceCodeInfo_mutable_location(google_protobuf_SourceCodeInfo* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo_msg_init(), 1); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -6403,12 +7008,16 @@ UPB_INLINE google_protobuf_SourceCodeInfo_Location** google_protobuf_SourceCodeI return NULL; } } -UPB_INLINE google_protobuf_SourceCodeInfo_Location** google_protobuf_SourceCodeInfo_resize_location(google_protobuf_SourceCodeInfo* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_SourceCodeInfo_Location** google_protobuf_SourceCodeInfo_resize_location(google_protobuf_SourceCodeInfo* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo_msg_init(), 1); - return (google_protobuf_SourceCodeInfo_Location**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_SourceCodeInfo_Location**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_SourceCodeInfo_Location* google_protobuf_SourceCodeInfo_add_location(google_protobuf_SourceCodeInfo* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_SourceCodeInfo_Location* google_protobuf_SourceCodeInfo_add_location( + google_protobuf_SourceCodeInfo* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo_msg_init(), 1); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -6416,7 +7025,8 @@ UPB_INLINE struct google_protobuf_SourceCodeInfo_Location* google_protobuf_Sourc arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_SourceCodeInfo_Location* sub = (struct google_protobuf_SourceCodeInfo_Location*)_upb_Message_New(google__protobuf__SourceCodeInfo__Location_msg_init(), arena); + struct google_protobuf_SourceCodeInfo_Location* sub = + (struct google_protobuf_SourceCodeInfo_Location*)_upb_Message_New(google__protobuf__SourceCodeInfo__Location_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); @@ -6424,37 +7034,39 @@ UPB_INLINE struct google_protobuf_SourceCodeInfo_Location* google_protobuf_Sourc } /* google.protobuf.SourceCodeInfo.Location */ - UPB_INLINE google_protobuf_SourceCodeInfo_Location* google_protobuf_SourceCodeInfo_Location_new(upb_Arena* arena) { return (google_protobuf_SourceCodeInfo_Location*)_upb_Message_New(google__protobuf__SourceCodeInfo__Location_msg_init(), arena); } -UPB_INLINE google_protobuf_SourceCodeInfo_Location* google_protobuf_SourceCodeInfo_Location_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_SourceCodeInfo_Location* google_protobuf_SourceCodeInfo_Location_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_SourceCodeInfo_Location* ret = google_protobuf_SourceCodeInfo_Location_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__SourceCodeInfo__Location_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__SourceCodeInfo__Location_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_SourceCodeInfo_Location* google_protobuf_SourceCodeInfo_Location_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_SourceCodeInfo_Location* google_protobuf_SourceCodeInfo_Location_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_SourceCodeInfo_Location* ret = google_protobuf_SourceCodeInfo_Location_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__SourceCodeInfo__Location_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__SourceCodeInfo__Location_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_SourceCodeInfo_Location_serialize(const google_protobuf_SourceCodeInfo_Location* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_SourceCodeInfo_Location_serialize(const google_protobuf_SourceCodeInfo_Location* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__SourceCodeInfo__Location_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_SourceCodeInfo_Location_serialize_ex(const google_protobuf_SourceCodeInfo_Location* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_SourceCodeInfo_Location_serialize_ex(const google_protobuf_SourceCodeInfo_Location* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__SourceCodeInfo__Location_msg_init(), options, arena, &ptr, len); return ptr; @@ -6463,7 +7075,8 @@ UPB_INLINE void google_protobuf_SourceCodeInfo_Location_clear_path(google_protob const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo__Location_msg_init(), 1); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE int32_t const* google_protobuf_SourceCodeInfo_Location_path(const google_protobuf_SourceCodeInfo_Location* msg, size_t* size) { +UPB_INLINE int32_t const* google_protobuf_SourceCodeInfo_Location_path(const google_protobuf_SourceCodeInfo_Location* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo__Location_msg_init(), 1); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -6474,7 +7087,10 @@ UPB_INLINE int32_t const* google_protobuf_SourceCodeInfo_Location_path(const goo return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_SourceCodeInfo_Location_path_upb_array(const google_protobuf_SourceCodeInfo_Location* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_SourceCodeInfo_Location_path_upb_array( + const google_protobuf_SourceCodeInfo_Location* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo__Location_msg_init(), 1); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -6482,7 +7098,9 @@ UPB_INLINE const upb_Array* _google_protobuf_SourceCodeInfo_Location_path_upb_ar } return arr; } -UPB_INLINE upb_Array* _google_protobuf_SourceCodeInfo_Location_path_mutable_upb_array(google_protobuf_SourceCodeInfo_Location* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_SourceCodeInfo_Location_path_mutable_upb_array( + google_protobuf_SourceCodeInfo_Location* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo__Location_msg_init(), 1); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -6495,7 +7113,8 @@ UPB_INLINE void google_protobuf_SourceCodeInfo_Location_clear_span(google_protob const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo__Location_msg_init(), 2); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE int32_t const* google_protobuf_SourceCodeInfo_Location_span(const google_protobuf_SourceCodeInfo_Location* msg, size_t* size) { +UPB_INLINE int32_t const* google_protobuf_SourceCodeInfo_Location_span(const google_protobuf_SourceCodeInfo_Location* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo__Location_msg_init(), 2); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -6506,7 +7125,10 @@ UPB_INLINE int32_t const* google_protobuf_SourceCodeInfo_Location_span(const goo return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_SourceCodeInfo_Location_span_upb_array(const google_protobuf_SourceCodeInfo_Location* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_SourceCodeInfo_Location_span_upb_array( + const google_protobuf_SourceCodeInfo_Location* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo__Location_msg_init(), 2); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -6514,7 +7136,9 @@ UPB_INLINE const upb_Array* _google_protobuf_SourceCodeInfo_Location_span_upb_ar } return arr; } -UPB_INLINE upb_Array* _google_protobuf_SourceCodeInfo_Location_span_mutable_upb_array(google_protobuf_SourceCodeInfo_Location* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_SourceCodeInfo_Location_span_mutable_upb_array( + google_protobuf_SourceCodeInfo_Location* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo__Location_msg_init(), 2); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -6559,7 +7183,8 @@ UPB_INLINE void google_protobuf_SourceCodeInfo_Location_clear_leading_detached_c const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo__Location_msg_init(), 6); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE upb_StringView const* google_protobuf_SourceCodeInfo_Location_leading_detached_comments(const google_protobuf_SourceCodeInfo_Location* msg, size_t* size) { +UPB_INLINE upb_StringView const* google_protobuf_SourceCodeInfo_Location_leading_detached_comments(const google_protobuf_SourceCodeInfo_Location* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo__Location_msg_init(), 6); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -6570,7 +7195,10 @@ UPB_INLINE upb_StringView const* google_protobuf_SourceCodeInfo_Location_leading return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_SourceCodeInfo_Location_leading_detached_comments_upb_array(const google_protobuf_SourceCodeInfo_Location* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_SourceCodeInfo_Location_leading_detached_comments_upb_array( + const google_protobuf_SourceCodeInfo_Location* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo__Location_msg_init(), 6); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -6578,7 +7206,9 @@ UPB_INLINE const upb_Array* _google_protobuf_SourceCodeInfo_Location_leading_det } return arr; } -UPB_INLINE upb_Array* _google_protobuf_SourceCodeInfo_Location_leading_detached_comments_mutable_upb_array(google_protobuf_SourceCodeInfo_Location* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_SourceCodeInfo_Location_leading_detached_comments_mutable_upb_array( + google_protobuf_SourceCodeInfo_Location* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo__Location_msg_init(), 6); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -6588,7 +7218,8 @@ UPB_INLINE upb_Array* _google_protobuf_SourceCodeInfo_Location_leading_detached_ return arr; } -UPB_INLINE int32_t* google_protobuf_SourceCodeInfo_Location_mutable_path(google_protobuf_SourceCodeInfo_Location* msg, size_t* size) { +UPB_INLINE int32_t* google_protobuf_SourceCodeInfo_Location_mutable_path(google_protobuf_SourceCodeInfo_Location* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo__Location_msg_init(), 1); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -6599,12 +7230,16 @@ UPB_INLINE int32_t* google_protobuf_SourceCodeInfo_Location_mutable_path(google_ return NULL; } } -UPB_INLINE int32_t* google_protobuf_SourceCodeInfo_Location_resize_path(google_protobuf_SourceCodeInfo_Location* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE int32_t* google_protobuf_SourceCodeInfo_Location_resize_path(google_protobuf_SourceCodeInfo_Location* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo__Location_msg_init(), 1); - return (int32_t*)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (int32_t*)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE bool google_protobuf_SourceCodeInfo_Location_add_path(google_protobuf_SourceCodeInfo_Location* msg, int32_t val, upb_Arena* arena) { +UPB_INLINE bool google_protobuf_SourceCodeInfo_Location_add_path(google_protobuf_SourceCodeInfo_Location* msg, int32_t val, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo__Location_msg_init(), 1); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -6616,7 +7251,8 @@ UPB_INLINE bool google_protobuf_SourceCodeInfo_Location_add_path(google_protobuf (arr, arr->UPB_PRIVATE(size) - 1, &val, sizeof(val)); return true; } -UPB_INLINE int32_t* google_protobuf_SourceCodeInfo_Location_mutable_span(google_protobuf_SourceCodeInfo_Location* msg, size_t* size) { +UPB_INLINE int32_t* google_protobuf_SourceCodeInfo_Location_mutable_span(google_protobuf_SourceCodeInfo_Location* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo__Location_msg_init(), 2); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -6627,12 +7263,16 @@ UPB_INLINE int32_t* google_protobuf_SourceCodeInfo_Location_mutable_span(google_ return NULL; } } -UPB_INLINE int32_t* google_protobuf_SourceCodeInfo_Location_resize_span(google_protobuf_SourceCodeInfo_Location* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE int32_t* google_protobuf_SourceCodeInfo_Location_resize_span(google_protobuf_SourceCodeInfo_Location* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo__Location_msg_init(), 2); - return (int32_t*)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (int32_t*)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE bool google_protobuf_SourceCodeInfo_Location_add_span(google_protobuf_SourceCodeInfo_Location* msg, int32_t val, upb_Arena* arena) { +UPB_INLINE bool google_protobuf_SourceCodeInfo_Location_add_span(google_protobuf_SourceCodeInfo_Location* msg, int32_t val, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo__Location_msg_init(), 2); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -6644,15 +7284,16 @@ UPB_INLINE bool google_protobuf_SourceCodeInfo_Location_add_span(google_protobuf (arr, arr->UPB_PRIVATE(size) - 1, &val, sizeof(val)); return true; } -UPB_INLINE void google_protobuf_SourceCodeInfo_Location_set_leading_comments(google_protobuf_SourceCodeInfo_Location *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_SourceCodeInfo_Location_set_leading_comments(google_protobuf_SourceCodeInfo_Location* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo__Location_msg_init(), 3); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_SourceCodeInfo_Location_set_trailing_comments(google_protobuf_SourceCodeInfo_Location *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_SourceCodeInfo_Location_set_trailing_comments(google_protobuf_SourceCodeInfo_Location* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo__Location_msg_init(), 4); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE upb_StringView* google_protobuf_SourceCodeInfo_Location_mutable_leading_detached_comments(google_protobuf_SourceCodeInfo_Location* msg, size_t* size) { +UPB_INLINE upb_StringView* google_protobuf_SourceCodeInfo_Location_mutable_leading_detached_comments(google_protobuf_SourceCodeInfo_Location* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo__Location_msg_init(), 6); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -6663,12 +7304,16 @@ UPB_INLINE upb_StringView* google_protobuf_SourceCodeInfo_Location_mutable_leadi return NULL; } } -UPB_INLINE upb_StringView* google_protobuf_SourceCodeInfo_Location_resize_leading_detached_comments(google_protobuf_SourceCodeInfo_Location* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE upb_StringView* google_protobuf_SourceCodeInfo_Location_resize_leading_detached_comments(google_protobuf_SourceCodeInfo_Location* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo__Location_msg_init(), 6); - return (upb_StringView*)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (upb_StringView*)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE bool google_protobuf_SourceCodeInfo_Location_add_leading_detached_comments(google_protobuf_SourceCodeInfo_Location* msg, upb_StringView val, upb_Arena* arena) { +UPB_INLINE bool google_protobuf_SourceCodeInfo_Location_add_leading_detached_comments(google_protobuf_SourceCodeInfo_Location* msg, upb_StringView val, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__SourceCodeInfo__Location_msg_init(), 6); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -6682,37 +7327,39 @@ UPB_INLINE bool google_protobuf_SourceCodeInfo_Location_add_leading_detached_com } /* google.protobuf.GeneratedCodeInfo */ - UPB_INLINE google_protobuf_GeneratedCodeInfo* google_protobuf_GeneratedCodeInfo_new(upb_Arena* arena) { return (google_protobuf_GeneratedCodeInfo*)_upb_Message_New(google__protobuf__GeneratedCodeInfo_msg_init(), arena); } -UPB_INLINE google_protobuf_GeneratedCodeInfo* google_protobuf_GeneratedCodeInfo_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_GeneratedCodeInfo* google_protobuf_GeneratedCodeInfo_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_GeneratedCodeInfo* ret = google_protobuf_GeneratedCodeInfo_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__GeneratedCodeInfo_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__GeneratedCodeInfo_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_GeneratedCodeInfo* google_protobuf_GeneratedCodeInfo_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_GeneratedCodeInfo* google_protobuf_GeneratedCodeInfo_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_GeneratedCodeInfo* ret = google_protobuf_GeneratedCodeInfo_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__GeneratedCodeInfo_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__GeneratedCodeInfo_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_GeneratedCodeInfo_serialize(const google_protobuf_GeneratedCodeInfo* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_GeneratedCodeInfo_serialize(const google_protobuf_GeneratedCodeInfo* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__GeneratedCodeInfo_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_GeneratedCodeInfo_serialize_ex(const google_protobuf_GeneratedCodeInfo* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_GeneratedCodeInfo_serialize_ex(const google_protobuf_GeneratedCodeInfo* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__GeneratedCodeInfo_msg_init(), options, arena, &ptr, len); return ptr; @@ -6721,7 +7368,8 @@ UPB_INLINE void google_protobuf_GeneratedCodeInfo_clear_annotation(google_protob const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__GeneratedCodeInfo_msg_init(), 1); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_GeneratedCodeInfo_Annotation* const* google_protobuf_GeneratedCodeInfo_annotation(const google_protobuf_GeneratedCodeInfo* msg, size_t* size) { +UPB_INLINE const google_protobuf_GeneratedCodeInfo_Annotation* const* google_protobuf_GeneratedCodeInfo_annotation(const google_protobuf_GeneratedCodeInfo* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__GeneratedCodeInfo_msg_init(), 1); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -6732,7 +7380,10 @@ UPB_INLINE const google_protobuf_GeneratedCodeInfo_Annotation* const* google_pro return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_GeneratedCodeInfo_annotation_upb_array(const google_protobuf_GeneratedCodeInfo* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_GeneratedCodeInfo_annotation_upb_array( + const google_protobuf_GeneratedCodeInfo* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__GeneratedCodeInfo_msg_init(), 1); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -6740,7 +7391,9 @@ UPB_INLINE const upb_Array* _google_protobuf_GeneratedCodeInfo_annotation_upb_ar } return arr; } -UPB_INLINE upb_Array* _google_protobuf_GeneratedCodeInfo_annotation_mutable_upb_array(google_protobuf_GeneratedCodeInfo* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_GeneratedCodeInfo_annotation_mutable_upb_array( + google_protobuf_GeneratedCodeInfo* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__GeneratedCodeInfo_msg_init(), 1); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -6750,7 +7403,8 @@ UPB_INLINE upb_Array* _google_protobuf_GeneratedCodeInfo_annotation_mutable_upb_ return arr; } -UPB_INLINE google_protobuf_GeneratedCodeInfo_Annotation** google_protobuf_GeneratedCodeInfo_mutable_annotation(google_protobuf_GeneratedCodeInfo* msg, size_t* size) { +UPB_INLINE google_protobuf_GeneratedCodeInfo_Annotation** google_protobuf_GeneratedCodeInfo_mutable_annotation(google_protobuf_GeneratedCodeInfo* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__GeneratedCodeInfo_msg_init(), 1); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -6761,12 +7415,16 @@ UPB_INLINE google_protobuf_GeneratedCodeInfo_Annotation** google_protobuf_Genera return NULL; } } -UPB_INLINE google_protobuf_GeneratedCodeInfo_Annotation** google_protobuf_GeneratedCodeInfo_resize_annotation(google_protobuf_GeneratedCodeInfo* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_GeneratedCodeInfo_Annotation** google_protobuf_GeneratedCodeInfo_resize_annotation(google_protobuf_GeneratedCodeInfo* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__GeneratedCodeInfo_msg_init(), 1); - return (google_protobuf_GeneratedCodeInfo_Annotation**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_GeneratedCodeInfo_Annotation**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_GeneratedCodeInfo_Annotation* google_protobuf_GeneratedCodeInfo_add_annotation(google_protobuf_GeneratedCodeInfo* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_GeneratedCodeInfo_Annotation* google_protobuf_GeneratedCodeInfo_add_annotation( + google_protobuf_GeneratedCodeInfo* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__GeneratedCodeInfo_msg_init(), 1); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -6774,7 +7432,8 @@ UPB_INLINE struct google_protobuf_GeneratedCodeInfo_Annotation* google_protobuf_ arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_GeneratedCodeInfo_Annotation* sub = (struct google_protobuf_GeneratedCodeInfo_Annotation*)_upb_Message_New(google__protobuf__GeneratedCodeInfo__Annotation_msg_init(), arena); + struct google_protobuf_GeneratedCodeInfo_Annotation* sub = + (struct google_protobuf_GeneratedCodeInfo_Annotation*)_upb_Message_New(google__protobuf__GeneratedCodeInfo__Annotation_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); @@ -6782,37 +7441,39 @@ UPB_INLINE struct google_protobuf_GeneratedCodeInfo_Annotation* google_protobuf_ } /* google.protobuf.GeneratedCodeInfo.Annotation */ - UPB_INLINE google_protobuf_GeneratedCodeInfo_Annotation* google_protobuf_GeneratedCodeInfo_Annotation_new(upb_Arena* arena) { return (google_protobuf_GeneratedCodeInfo_Annotation*)_upb_Message_New(google__protobuf__GeneratedCodeInfo__Annotation_msg_init(), arena); } -UPB_INLINE google_protobuf_GeneratedCodeInfo_Annotation* google_protobuf_GeneratedCodeInfo_Annotation_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_GeneratedCodeInfo_Annotation* google_protobuf_GeneratedCodeInfo_Annotation_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_GeneratedCodeInfo_Annotation* ret = google_protobuf_GeneratedCodeInfo_Annotation_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__GeneratedCodeInfo__Annotation_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__GeneratedCodeInfo__Annotation_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_GeneratedCodeInfo_Annotation* google_protobuf_GeneratedCodeInfo_Annotation_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_GeneratedCodeInfo_Annotation* google_protobuf_GeneratedCodeInfo_Annotation_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_GeneratedCodeInfo_Annotation* ret = google_protobuf_GeneratedCodeInfo_Annotation_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__GeneratedCodeInfo__Annotation_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__GeneratedCodeInfo__Annotation_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_GeneratedCodeInfo_Annotation_serialize(const google_protobuf_GeneratedCodeInfo_Annotation* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_GeneratedCodeInfo_Annotation_serialize(const google_protobuf_GeneratedCodeInfo_Annotation* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__GeneratedCodeInfo__Annotation_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_GeneratedCodeInfo_Annotation_serialize_ex(const google_protobuf_GeneratedCodeInfo_Annotation* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_GeneratedCodeInfo_Annotation_serialize_ex(const google_protobuf_GeneratedCodeInfo_Annotation* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__GeneratedCodeInfo__Annotation_msg_init(), options, arena, &ptr, len); return ptr; @@ -6821,7 +7482,8 @@ UPB_INLINE void google_protobuf_GeneratedCodeInfo_Annotation_clear_path(google_p const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__GeneratedCodeInfo__Annotation_msg_init(), 1); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE int32_t const* google_protobuf_GeneratedCodeInfo_Annotation_path(const google_protobuf_GeneratedCodeInfo_Annotation* msg, size_t* size) { +UPB_INLINE int32_t const* google_protobuf_GeneratedCodeInfo_Annotation_path(const google_protobuf_GeneratedCodeInfo_Annotation* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__GeneratedCodeInfo__Annotation_msg_init(), 1); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -6832,7 +7494,10 @@ UPB_INLINE int32_t const* google_protobuf_GeneratedCodeInfo_Annotation_path(cons return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_GeneratedCodeInfo_Annotation_path_upb_array(const google_protobuf_GeneratedCodeInfo_Annotation* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_GeneratedCodeInfo_Annotation_path_upb_array( + const google_protobuf_GeneratedCodeInfo_Annotation* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__GeneratedCodeInfo__Annotation_msg_init(), 1); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -6840,7 +7505,9 @@ UPB_INLINE const upb_Array* _google_protobuf_GeneratedCodeInfo_Annotation_path_u } return arr; } -UPB_INLINE upb_Array* _google_protobuf_GeneratedCodeInfo_Annotation_path_mutable_upb_array(google_protobuf_GeneratedCodeInfo_Annotation* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_GeneratedCodeInfo_Annotation_path_mutable_upb_array( + google_protobuf_GeneratedCodeInfo_Annotation* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__GeneratedCodeInfo__Annotation_msg_init(), 1); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -6914,7 +7581,8 @@ UPB_INLINE bool google_protobuf_GeneratedCodeInfo_Annotation_has_semantic(const return upb_Message_HasBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE int32_t* google_protobuf_GeneratedCodeInfo_Annotation_mutable_path(google_protobuf_GeneratedCodeInfo_Annotation* msg, size_t* size) { +UPB_INLINE int32_t* google_protobuf_GeneratedCodeInfo_Annotation_mutable_path(google_protobuf_GeneratedCodeInfo_Annotation* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__GeneratedCodeInfo__Annotation_msg_init(), 1); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -6925,12 +7593,16 @@ UPB_INLINE int32_t* google_protobuf_GeneratedCodeInfo_Annotation_mutable_path(go return NULL; } } -UPB_INLINE int32_t* google_protobuf_GeneratedCodeInfo_Annotation_resize_path(google_protobuf_GeneratedCodeInfo_Annotation* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE int32_t* google_protobuf_GeneratedCodeInfo_Annotation_resize_path(google_protobuf_GeneratedCodeInfo_Annotation* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__GeneratedCodeInfo__Annotation_msg_init(), 1); - return (int32_t*)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (int32_t*)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE bool google_protobuf_GeneratedCodeInfo_Annotation_add_path(google_protobuf_GeneratedCodeInfo_Annotation* msg, int32_t val, upb_Arena* arena) { +UPB_INLINE bool google_protobuf_GeneratedCodeInfo_Annotation_add_path(google_protobuf_GeneratedCodeInfo_Annotation* msg, int32_t val, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__GeneratedCodeInfo__Annotation_msg_init(), 1); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -6942,31 +7614,30 @@ UPB_INLINE bool google_protobuf_GeneratedCodeInfo_Annotation_add_path(google_pro (arr, arr->UPB_PRIVATE(size) - 1, &val, sizeof(val)); return true; } -UPB_INLINE void google_protobuf_GeneratedCodeInfo_Annotation_set_source_file(google_protobuf_GeneratedCodeInfo_Annotation *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_GeneratedCodeInfo_Annotation_set_source_file(google_protobuf_GeneratedCodeInfo_Annotation* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__GeneratedCodeInfo__Annotation_msg_init(), 2); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_GeneratedCodeInfo_Annotation_set_begin(google_protobuf_GeneratedCodeInfo_Annotation *msg, int32_t value) { +UPB_INLINE void google_protobuf_GeneratedCodeInfo_Annotation_set_begin(google_protobuf_GeneratedCodeInfo_Annotation* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__GeneratedCodeInfo__Annotation_msg_init(), 3); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_GeneratedCodeInfo_Annotation_set_end(google_protobuf_GeneratedCodeInfo_Annotation *msg, int32_t value) { +UPB_INLINE void google_protobuf_GeneratedCodeInfo_Annotation_set_end(google_protobuf_GeneratedCodeInfo_Annotation* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__GeneratedCodeInfo__Annotation_msg_init(), 4); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_GeneratedCodeInfo_Annotation_set_semantic(google_protobuf_GeneratedCodeInfo_Annotation *msg, int32_t value) { +UPB_INLINE void google_protobuf_GeneratedCodeInfo_Annotation_set_semantic(google_protobuf_GeneratedCodeInfo_Annotation* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__GeneratedCodeInfo__Annotation_msg_init(), 5); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } /* Max size 32 is google.protobuf.FileOptions */ /* Max size 64 is google.protobuf.FileOptions */ #define _UPB_MAXOPT_SIZE UPB_SIZE(112, 200) - #ifdef __cplusplus -} /* extern "C" */ + } /* extern "C" */ #endif #include "upb/port/undef.inc" -#endif /* GOOGLE_PROTOBUF_DESCRIPTOR_PROTO_UPB_H__UPB_H_ */ +#endif /* GOOGLE_PROTOBUF_DESCRIPTOR_PROTO_UPB_H__UPB_H_ */ diff --git a/upb_generator/c/BUILD b/upb_generator/c/BUILD index 7b8f0fd66a24a..e9cc806d017a7 100644 --- a/upb_generator/c/BUILD +++ b/upb_generator/c/BUILD @@ -58,6 +58,8 @@ bootstrap_cc_binary( ":names_internal", "//src/google/protobuf/compiler:code_generator", "//src/google/protobuf/compiler:plugin", + "//src/google/protobuf/io", + "//src/google/protobuf/io:printer", "//upb/base", "//upb/mem", "//upb/mini_table", @@ -73,7 +75,7 @@ bootstrap_cc_binary( "@abseil-cpp//absl/log:absl_log", "@abseil-cpp//absl/memory", "@abseil-cpp//absl/strings", - "@abseil-cpp//absl/strings:cord", + "@abseil-cpp//absl/types:span", ], ) diff --git a/upb_generator/c/generator.cc b/upb_generator/c/generator.cc index 297df96ecf388..bb6ff108d4077 100644 --- a/upb_generator/c/generator.cc +++ b/upb_generator/c/generator.cc @@ -22,9 +22,7 @@ #include "absl/base/macros.h" #include "absl/container/flat_hash_set.h" #include "absl/log/absl_check.h" -#include "absl/log/absl_log.h" #include "absl/memory/memory.h" -#include "absl/strings/cord.h" #include "absl/strings/escaping.h" #include "absl/strings/match.h" #include "absl/strings/numbers.h" @@ -32,10 +30,11 @@ #include "absl/strings/str_replace.h" #include "absl/strings/string_view.h" #include "absl/strings/substitute.h" +#include "absl/types/span.h" #include "google/protobuf/compiler/code_generator.h" #include "google/protobuf/compiler/plugin.h" +#include "google/protobuf/io/printer.h" #include "upb/base/descriptor_constants.h" -#include "upb/base/status.hpp" #include "upb/base/string_view.h" #include "upb/mem/arena.hpp" #include "upb/mini_table/field.h" @@ -56,11 +55,42 @@ namespace upb { namespace generator { namespace { +using Printer = google::protobuf::io::Printer; +using Sub = google::protobuf::io::Printer::Sub; + struct Options { int bootstrap_stage = -1; // -1 means not bootstrapped. bool strip_nonfunctional_codegen = false; }; +class Context { + public: + Context(const DefPoolPair& pools, const Options& options, + google::protobuf::io::Printer& printer) + : pools_(pools), options_(options), printer_(printer) {} + + const DefPoolPair& pools() const { return pools_; } + const Options& options() const { return options_; } + + // A few convenience wrappers so that users can write `ctx.Emit()` instead of + // `ctx.printer().Emit()`. + void Emit(absl::Span vars, + absl::string_view format, + Printer::SourceLocation loc = Printer::SourceLocation::current()) { + printer_.Emit(vars, format, loc); + } + + void Emit(absl::string_view format, + Printer::SourceLocation loc = Printer::SourceLocation::current()) { + printer_.Emit(format, loc); + } + + private: + const DefPoolPair& pools_; + const Options& options_; + Printer& printer_; +}; + // Local convenience aliases for the public names.h header files. std::string ExtensionIdentBase(upb::FieldDefPtr field) { @@ -252,7 +282,7 @@ std::string FieldInitializerStrong(const DefPoolPair& pools, upb::FieldDefPtr field, const Options& options); -void DumpEnumValues(upb::EnumDefPtr desc, Output& output) { +void DumpEnumValues(Context& c, upb::EnumDefPtr desc) { std::vector values; values.reserve(desc.value_count()); for (int i = 0; i < desc.value_count(); i++) { @@ -265,11 +295,15 @@ void DumpEnumValues(upb::EnumDefPtr desc, Output& output) { for (size_t i = 0; i < values.size(); i++) { auto value = values[i]; - output(" $0 = $1", EnumValueSymbol(value), value.number()); - if (i != values.size() - 1) { - output(","); - } - output("\n"); + c.Emit( + { + {"name", EnumValueSymbol(value)}, + {"number", absl::StrCat(value.number())}, + {"comma", i == values.size() - 1 ? "" : ","}, + }, + R"cc( + $name$ = $number$$comma$ + )cc"); } } @@ -278,222 +312,262 @@ std::string GetFieldRep(const DefPoolPair& pools, upb::FieldDefPtr field) { pools.GetField64(field)); } -void GenerateExtensionInHeader(const DefPoolPair& pools, upb::FieldDefPtr ext, - const Options& options, Output& output) { - output( +void GenerateExtensionInHeader(Context& c, upb::FieldDefPtr ext) { + c.Emit( + { + {"ident_base", ExtensionIdentBase(ext)}, + {"name", ext.name()}, + {"ctype", MessageType(ext.containing_type())}, + {"ext_var", MiniTableExtensionVarName(ext.full_name())}, + }, R"cc( - UPB_INLINE bool $0_has_$1(const struct $2* msg) { - return upb_Message_HasExtension((upb_Message*)msg, &$3); + UPB_INLINE bool $ident_base$_has_$name$(const struct $ctype$* msg) { + return upb_Message_HasExtension((upb_Message*)msg, &$ext_var$); } - )cc", - ExtensionIdentBase(ext), ext.name(), MessageType(ext.containing_type()), - MiniTableExtensionVarName(ext.full_name())); - output( - R"cc( - UPB_INLINE void $0_clear_$1(struct $2* msg) { - upb_Message_ClearExtension((upb_Message*)msg, &$3); + UPB_INLINE void $ident_base$_clear_$name$(struct $ctype$* msg) { + upb_Message_ClearExtension((upb_Message*)msg, &$ext_var$); } - )cc", - ExtensionIdentBase(ext), ext.name(), MessageType(ext.containing_type()), - MiniTableExtensionVarName(ext.full_name())); + )cc"); if (ext.IsSequence()) { // TODO: We need generated accessors for repeated extensions. } else { - output( + c.Emit( + { + {"ctype_const", CTypeConst(ext)}, + {"ident_base", ExtensionIdentBase(ext)}, + {"name", ext.name()}, + {"ctype", MessageType(ext.containing_type())}, + {"ext_var", MiniTableExtensionVarName(ext.full_name())}, + {"rep", GetFieldRep(c.pools(), ext)}, + {"default", FieldDefault(ext)}, + }, R"cc( - UPB_INLINE $0 $1_$2(const struct $3* msg) { - const upb_MiniTableExtension* ext = &$4; + UPB_INLINE $ctype_const$ + $ident_base$_$name$(const struct $ctype$* msg) { + const upb_MiniTableExtension* ext = &$ext_var$; UPB_ASSUME(upb_MiniTableField_IsScalar(&ext->UPB_PRIVATE(field))); UPB_ASSUME(UPB_PRIVATE(_upb_MiniTableField_GetRep)( - &ext->UPB_PRIVATE(field)) == $5); - $0 default_val = $6; - $0 ret; + &ext->UPB_PRIVATE(field)) == $rep$); + $ctype_const$ default_val = $default$; + $ctype_const$ ret; _upb_Message_GetExtensionField((upb_Message*)msg, ext, &default_val, &ret); return ret; } - )cc", - CTypeConst(ext), ExtensionIdentBase(ext), ext.name(), - MessageType(ext.containing_type()), - MiniTableExtensionVarName(ext.full_name()), GetFieldRep(pools, ext), - FieldDefault(ext)); - output( - R"cc( - UPB_INLINE void $1_set_$2(struct $3* msg, $0 val, upb_Arena* arena) { - const upb_MiniTableExtension* ext = &$4; + + UPB_INLINE void $ident_base$_set_$name$(struct $ctype$* msg, + $ctype_const$ val, + upb_Arena* arena) { + const upb_MiniTableExtension* ext = &$ext_var$; UPB_ASSUME(upb_MiniTableField_IsScalar(&ext->UPB_PRIVATE(field))); UPB_ASSUME(UPB_PRIVATE(_upb_MiniTableField_GetRep)( - &ext->UPB_PRIVATE(field)) == $5); + &ext->UPB_PRIVATE(field)) == $rep$); bool ok = upb_Message_SetExtension((upb_Message*)msg, ext, &val, arena); UPB_ASSERT(ok); } - )cc", - CTypeConst(ext), ExtensionIdentBase(ext), ext.name(), - MessageType(ext.containing_type()), - MiniTableExtensionVarName(ext.full_name()), GetFieldRep(pools, ext)); + )cc"); // Message extensions also have a Msg_mutable_foo() accessor that will // create the sub-message if it doesn't already exist. if (ext.IsSubMessage()) { - output( + c.Emit( + { + {"sub_ctype", MessageType(ext.message_type())}, + {"ident_base", ExtensionIdentBase(ext)}, + {"name", ext.name()}, + {"ctype", MessageType(ext.containing_type())}, + {"mini_table", + MessageMiniTableRef(ext.message_type(), c.options())}, + }, R"cc( - UPB_INLINE struct $0* $1_mutable_$2(struct $3* msg, - upb_Arena* arena) { - struct $0* sub = (struct $0*)$1_$2(msg); + UPB_INLINE struct $sub_ctype$* $ident_base$_mutable_$name$( + struct $ctype$* msg, upb_Arena* arena) { + struct $sub_ctype$* sub = (struct $sub_ctype$*)$ident_base$_$name$(msg); if (sub == NULL) { - sub = (struct $0*)_upb_Message_New($4, arena); - if (sub) $1_set_$2(msg, sub, arena); + sub = (struct $sub_ctype$*)_upb_Message_New($mini_table$, arena); + if (sub) $ident_base$_set_$name$(msg, sub, arena); } return sub; } - )cc", - MessageType(ext.message_type()), ExtensionIdentBase(ext), ext.name(), - MessageType(ext.containing_type()), - MessageMiniTableRef(ext.message_type(), options)); + )cc"); } } } -void GenerateMessageFunctionsInHeader(upb::MessageDefPtr message, - const Options& options, Output& output) { +void GenerateMessageFunctionsInHeader(Context& c, upb::MessageDefPtr message) { // TODO: The generated code here does not check the return values // from upb_Encode(). How can we even fix this without breaking other things? - output( + c.Emit( + { + {"msg_type", MessageType(message)}, + {"mini_table", MessageMiniTableRef(message, c.options())}, + }, R"cc( - UPB_INLINE $0* $0_new(upb_Arena* arena) { - return ($0*)_upb_Message_New($1, arena); + UPB_INLINE $msg_type$* $msg_type$_new(upb_Arena* arena) { + return ($msg_type$*)_upb_Message_New($mini_table$, arena); } - UPB_INLINE $0* $0_parse(const char* buf, size_t size, upb_Arena* arena) { - $0* ret = $0_new(arena); + UPB_INLINE $msg_type$* $msg_type$_parse(const char* buf, size_t size, + upb_Arena* arena) { + $msg_type$* ret = $msg_type$_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), $1, NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), $mini_table$, NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } - UPB_INLINE $0* $0_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { - $0* ret = $0_new(arena); + UPB_INLINE $msg_type$* $msg_type$_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { + $msg_type$* ret = $msg_type$_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), $1, extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), $mini_table$, extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } - UPB_INLINE char* $0_serialize(const $0* msg, upb_Arena* arena, size_t* len) { + UPB_INLINE char* $msg_type$_serialize(const $msg_type$* msg, + upb_Arena* arena, size_t* len) { char* ptr; - (void)upb_Encode(UPB_UPCAST(msg), $1, 0, arena, &ptr, len); + (void)upb_Encode(UPB_UPCAST(msg), $mini_table$, 0, arena, &ptr, len); return ptr; } - UPB_INLINE char* $0_serialize_ex(const $0* msg, int options, - upb_Arena* arena, size_t* len) { + UPB_INLINE char* $msg_type$_serialize_ex(const $msg_type$* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; - (void)upb_Encode(UPB_UPCAST(msg), $1, options, arena, &ptr, len); + (void)upb_Encode(UPB_UPCAST(msg), $mini_table$, options, arena, &ptr, len); return ptr; } - )cc", - MessageType(message), MessageMiniTableRef(message, options)); + )cc"); } -void GenerateOneofInHeader(upb::OneofDefPtr oneof, const DefPoolPair& pools, - absl::string_view msg_name, const Options& options, - Output& output) { - std::string fullname = CApiOneofIdentBase(oneof.full_name()); - output("typedef enum {\n"); - for (int j = 0; j < oneof.field_count(); j++) { - upb::FieldDefPtr field = oneof.field(j); - output(" $0_$1 = $2,\n", fullname, field.name(), field.number()); +void GenerateOneofCases(Context& c, upb::OneofDefPtr oneof) { + std::string base = CApiOneofIdentBase(oneof.full_name()); + for (int i = 0; i < oneof.field_count(); i++) { + upb::FieldDefPtr field = oneof.field(i); + c.Emit( + { + {"base", base}, + {"name", field.name()}, + {"number", absl::StrCat(field.number())}, + }, + R"cc( + $base$_$name$ = $number$, + )cc"); } - output( - " $0_NOT_SET = 0\n" - "} $0_oneofcases;\n", - fullname); - output( +} + +void GenerateOneofInHeader(Context& c, upb::OneofDefPtr oneof, + absl::string_view msg_name) { + c.Emit( + { + {"fullname", CApiOneofIdentBase(oneof.full_name())}, + {"msg_name", msg_name}, + {"oneof_name", oneof.name()}, + {"field_init", + FieldInitializer(c.pools(), oneof.field(0), c.options())}, + {"mini_table", + MessageMiniTableRef(oneof.containing_type(), c.options())}, + Sub("cases", [&]() { GenerateOneofCases(c, oneof); }).WithSuffix(","), + }, R"cc( - UPB_INLINE $0_oneofcases $1_$2_case(const $1* msg) { - const upb_MiniTableField field = $3; - return ($0_oneofcases)upb_Message_WhichOneofFieldNumber( + typedef enum { + $cases$, + $fullname$_NOT_SET = 0 + } $fullname$_oneofcases; + + UPB_INLINE $fullname$_oneofcases + $msg_name$_$oneof_name$_case(const $msg_name$* msg) { + const upb_MiniTableField field = $field_init$; + return ($fullname$_oneofcases)upb_Message_WhichOneofFieldNumber( UPB_UPCAST(msg), &field); } - UPB_INLINE void $1_clear_$2($1* msg) { - const upb_MiniTableField field = $3; - upb_Message_ClearOneof(UPB_UPCAST(msg), $4, &field); + UPB_INLINE void $msg_name$_clear_$oneof_name$($msg_name$* msg) { + const upb_MiniTableField field = $field_init$; + upb_Message_ClearOneof(UPB_UPCAST(msg), $mini_table$, &field); } - )cc", - fullname, msg_name, oneof.name(), - FieldInitializer(pools, oneof.field(0), options), - MessageMiniTableRef(oneof.containing_type(), options)); + )cc"); } -void GenerateHazzer(upb::FieldDefPtr field, const DefPoolPair& pools, - absl::string_view msg_name, const NameMangler& mangler, - const Options& options, Output& output) { +void GenerateHazzer(Context& c, upb::FieldDefPtr field, + absl::string_view msg_name, const NameMangler& mangler) { std::string resolved_name = mangler.ResolveFieldName(field.name()); if (field.has_presence()) { - output( + c.Emit( + { + {"msg_name", msg_name}, + {"name", resolved_name}, + {"field_init", FieldInitializer(c.pools(), field, c.options())}, + }, R"cc( - UPB_INLINE bool $0_has_$1(const $0* msg) { - const upb_MiniTableField field = $2; + UPB_INLINE bool $msg_name$_has_$name$(const $msg_name$* msg) { + const upb_MiniTableField field = $field_init$; return upb_Message_HasBaseField(UPB_UPCAST(msg), &field); } - )cc", - msg_name, resolved_name, FieldInitializer(pools, field, options)); + )cc"); } } -void GenerateClear(upb::FieldDefPtr field, const DefPoolPair& pools, - absl::string_view msg_name, const NameMangler& mangler, - const Options& options, Output& output) { +void GenerateClear(Context& c, upb::FieldDefPtr field, + absl::string_view msg_name, const NameMangler& mangler) { if (field == field.containing_type().map_key() || field == field.containing_type().map_value()) { // Cannot be cleared. return; } - std::string resolved_name = mangler.ResolveFieldName(field.name()); - output( + c.Emit( + { + {"msg_name", msg_name}, + {"name", mangler.ResolveFieldName(field.name())}, + {"field_init", FieldInitializer(c.pools(), field, c.options())}, + }, R"cc( - UPB_INLINE void $0_clear_$1($0* msg) { - const upb_MiniTableField field = $2; + UPB_INLINE void $msg_name$_clear_$name$($msg_name$* msg) { + const upb_MiniTableField field = $field_init$; upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } - )cc", - msg_name, resolved_name, FieldInitializer(pools, field, options)); + )cc"); } -void GenerateMapGetters(upb::FieldDefPtr field, const DefPoolPair& pools, - absl::string_view msg_name, const NameMangler& mangler, - const Options& options, Output& output) { - std::string resolved_name = mangler.ResolveFieldName(field.name()); - output( +void GenerateMapGetters(Context& c, upb::FieldDefPtr field, + absl::string_view msg_name, + const NameMangler& mangler) { + c.Emit( + { + {"msg_name", msg_name}, + {"name", mangler.ResolveFieldName(field.name())}, + {"key_type", MapKeyCType(field)}, + {"val_type", MapValueCType(field)}, + {"val_type_const", MapValueCTypeConst(field)}, + {"key_size", MapKeySize(field, MapKeyCType(field))}, + {"val_size", MapValueSize(field, MapValueCType(field))}, + {"field_init", FieldInitializerStrong(c.pools(), field, c.options())}, + {"map_getter", kMapGetterPostfix}, + {"mutable_map_getter", kMutableMapGetterPostfix}, + }, R"cc( - UPB_INLINE size_t $0_$1_size(const $0* msg) { - const upb_MiniTableField field = $2; + UPB_INLINE size_t $msg_name$_$name$_size(const $msg_name$* msg) { + const upb_MiniTableField field = $field_init$; const upb_Map* map = upb_Message_GetMap(UPB_UPCAST(msg), &field); return map ? _upb_Map_Size(map) : 0; } - )cc", - msg_name, resolved_name, FieldInitializer(pools, field, options)); - output( - R"cc( - UPB_INLINE bool $0_$1_get(const $0* msg, $2 key, $3* val) { - const upb_MiniTableField field = $4; + + UPB_INLINE bool $msg_name$_$name$_get(const $msg_name$* msg, + $key_type$ key, $val_type$* val) { + const upb_MiniTableField field = $field_init$; const upb_Map* map = upb_Message_GetMap(UPB_UPCAST(msg), &field); if (!map) return false; - return _upb_Map_Get(map, &key, $5, val, $6); + return _upb_Map_Get(map, &key, $key_size$, val, $val_size$); } - )cc", - msg_name, resolved_name, MapKeyCType(field), MapValueCType(field), - FieldInitializerStrong(pools, field, options), MapKeySize(field, "key"), - MapValueSize(field, "*val")); - output( - R"cc( - UPB_INLINE bool $0_$1_next(const $0* msg, $2* key, $3* val, - size_t* iter) { - const upb_MiniTableField field = $4; + + UPB_INLINE bool $msg_name$_$name$_next(const $msg_name$* msg, + $key_type$* key, + $val_type_const$* val, + size_t* iter) { + const upb_MiniTableField field = $field_init$; const upb_Map* map = upb_Message_GetMap(UPB_UPCAST(msg), &field); if (!map) return false; upb_MessageValue k; @@ -503,77 +577,77 @@ void GenerateMapGetters(upb::FieldDefPtr field, const DefPoolPair& pools, memcpy(val, &v, sizeof(*val)); return true; } - )cc", - msg_name, resolved_name, MapKeyCType(field), MapValueCTypeConst(field), - FieldInitializerStrong(pools, field, options)); - // Generate private getter returning a upb_Map or NULL for immutable and - // a upb_Map for mutable. - // - // Example: - // UPB_INLINE const upb_Map* _name_immutable_upb_map(Foo* msg) - // UPB_INLINE upb_Map* _name_mutable_upb_map(Foo* msg, upb_Arena* a) - output( - R"cc( - UPB_INLINE const upb_Map* _$0_$1_$2($0* msg) { - const upb_MiniTableField field = $4; + + //~ Generate private getter returning a upb_Map or NULL for immutable + // and ~ a upb_Map for mutable. + // + //~ Example: + //~ UPB_INLINE const upb_Map* _name_immutable_upb_map(Foo* msg) + //~ UPB_INLINE upb_Map* _name_mutable_upb_map(Foo* msg, upb_Arena* a) + UPB_INLINE const upb_Map* _$msg_name$_$name$_$map_getter$($msg_name$* msg) { + const upb_MiniTableField field = $field_init$; return upb_Message_GetMap(UPB_UPCAST(msg), &field); } - UPB_INLINE upb_Map* _$0_$1_$3($0* msg, upb_Arena* a) { - const upb_MiniTableField field = $4; - return _upb_Message_GetOrCreateMutableMap(UPB_UPCAST(msg), &field, $5, $6, a); + + UPB_INLINE upb_Map* _$msg_name$_$name$_$mutable_map_getter$( + $msg_name$* msg, upb_Arena* a) { + const upb_MiniTableField field = $field_init$; + return _upb_Message_GetOrCreateMutableMap(UPB_UPCAST(msg), &field, + $key_size$, $val_size$, a); } - )cc", - msg_name, resolved_name, kMapGetterPostfix, kMutableMapGetterPostfix, - FieldInitializerStrong(pools, field, options), - MapKeySize(field, MapKeyCType(field)), - MapValueSize(field, MapValueCType(field))); + )cc"); } -void GenerateRepeatedGetters(upb::FieldDefPtr field, const DefPoolPair& pools, +void GenerateRepeatedGetters(Context& c, upb::FieldDefPtr field, absl::string_view msg_name, - const NameMangler& mangler, const Options& options, - Output& output) { - // Generate getter returning first item and size. - // - // Example: - // UPB_INLINE const struct Bar* const* name(const Foo* msg, size_t* size) - output( + const NameMangler& mangler) { + c.Emit( + { + {"msg_name", msg_name}, + {"name", mangler.ResolveFieldName(field.name())}, + {"ctype_const", CTypeConst(field)}, + {"field_init", FieldInitializerStrong(c.pools(), field, c.options())}, + {"array_getter", kRepeatedFieldArrayGetterPostfix}, + {"mutable_array_getter", kRepeatedFieldMutableArrayGetterPostfix}, + }, R"cc( - UPB_INLINE $0 const* $1_$2(const $1* msg, size_t* size) { - const upb_MiniTableField field = $3; + //~ Generate getter returning first item and size. + //~ + //~ Example: + //~ UPB_INLINE const struct Bar* const* name(const Foo* msg, + //~ size_t* size) + UPB_INLINE $ctype_const$ const* $msg_name$_$name$(const $msg_name$* msg, + size_t* size) { + const upb_MiniTableField field = $field_init$; const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { if (size) *size = arr->UPB_PRIVATE(size); - return ($0 const*)upb_Array_DataPtr(arr); + return ($ctype_const$ const*)upb_Array_DataPtr(arr); } else { if (size) *size = 0; return NULL; } } - )cc", - CTypeConst(field), // $0 - msg_name, // $1 - mangler.ResolveFieldName(field.name()), // $2 - FieldInitializerStrong(pools, field, options) // #3 - ); - // Generate private getter returning array or NULL for immutable and upb_Array - // for mutable. - // - // Example: - // UPB_INLINE const upb_Array* _name_upbarray(size_t* size) - // UPB_INLINE upb_Array* _name_mutable_upbarray(size_t* size) - output( - R"cc( - UPB_INLINE const upb_Array* _$1_$2_$4(const $1* msg, size_t* size) { - const upb_MiniTableField field = $3; + + //~ Generate private getter returning array or NULL for immutable and + //~ upb_Array for mutable. + // + //~ Example: + //~ UPB_INLINE const upb_Array* _name_upbarray(size_t* size) + //~ UPB_INLINE upb_Array* _name_mutable_upbarray(size_t* size) + UPB_INLINE const upb_Array* _$msg_name$_$name$_$array_getter$( + const $msg_name$* msg, size_t* size) { + const upb_MiniTableField field = $field_init$; const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { *size = arr ? arr->UPB_PRIVATE(size) : 0; } return arr; } - UPB_INLINE upb_Array* _$1_$2_$5($1* msg, size_t* size, upb_Arena* arena) { - const upb_MiniTableField field = $3; + + UPB_INLINE upb_Array* _$msg_name$_$name$_$mutable_array_getter$( + $msg_name$* msg, size_t* size, upb_Arena* arena) { + const upb_MiniTableField field = $field_init$; upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); if (size) { @@ -581,145 +655,155 @@ void GenerateRepeatedGetters(upb::FieldDefPtr field, const DefPoolPair& pools, } return arr; } - )cc", - CTypeConst(field), // $0 - msg_name, // $1 - mangler.ResolveFieldName(field.name()), // $2 - FieldInitializerStrong(pools, field, options), // $3 - kRepeatedFieldArrayGetterPostfix, // $4 - kRepeatedFieldMutableArrayGetterPostfix // $5 - ); + )cc"); } -void GenerateScalarGetters(upb::FieldDefPtr field, const DefPoolPair& pools, +void GenerateScalarGetters(Context& c, upb::FieldDefPtr field, absl::string_view msg_name, - const NameMangler& mangler, const Options& Options, - Output& output) { + const NameMangler& mangler) { std::string field_name = mangler.ResolveFieldName(field.name()); - output( + c.Emit( + { + {"ctype_const", CTypeConst(field)}, + {"msg_name", msg_name}, + {"name", field_name}, + {"default", FieldDefault(field)}, + {"field_init", FieldInitializerStrong(c.pools(), field, c.options())}, + }, R"cc( - UPB_INLINE $0 $1_$2(const $1* msg) { - $0 default_val = $3; - $0 ret; - const upb_MiniTableField field = $4; + UPB_INLINE $ctype_const$ $msg_name$_$name$(const $msg_name$* msg) { + $ctype_const$ default_val = $default$; + $ctype_const$ ret; + const upb_MiniTableField field = $field_init$; _upb_Message_GetNonExtensionField(UPB_UPCAST(msg), &field, &default_val, &ret); return ret; } - )cc", - CTypeConst(field), msg_name, field_name, FieldDefault(field), - FieldInitializerStrong(pools, field, Options)); + )cc"); } -void GenerateGetters(upb::FieldDefPtr field, const DefPoolPair& pools, - absl::string_view msg_name, const NameMangler& mangler, - const Options& options, Output& output) { +void GenerateGetters(Context& c, upb::FieldDefPtr field, + absl::string_view msg_name, const NameMangler& mangler) { if (field.IsMap()) { - GenerateMapGetters(field, pools, msg_name, mangler, options, output); + GenerateMapGetters(c, field, msg_name, mangler); } else if (field.IsSequence()) { - GenerateRepeatedGetters(field, pools, msg_name, mangler, options, output); + GenerateRepeatedGetters(c, field, msg_name, mangler); } else { - GenerateScalarGetters(field, pools, msg_name, mangler, options, output); + GenerateScalarGetters(c, field, msg_name, mangler); } } -void GenerateMapSetters(upb::FieldDefPtr field, const DefPoolPair& pools, - absl::string_view msg_name, const NameMangler& mangler, - const Options& options, Output& output) { - std::string resolved_name = mangler.ResolveFieldName(field.name()); - output( +void GenerateMapSetters(Context& c, upb::FieldDefPtr field, + absl::string_view msg_name, + const NameMangler& mangler) { + c.Emit( + { + {"msg_name", msg_name}, + {"name", mangler.ResolveFieldName(field.name())}, + {"key_type", MapKeyCType(field)}, + {"val_type", MapValueCType(field)}, + {"field_init", FieldInitializerStrong(c.pools(), field, c.options())}, + {"key_size", MapKeySize(field, "key")}, + {"val_size", MapValueSize(field, "val")}, + }, R"cc( - UPB_INLINE void $0_$1_clear($0* msg) { - const upb_MiniTableField field = $2; + UPB_INLINE void $msg_name$_$name$_clear($msg_name$* msg) { + const upb_MiniTableField field = $field_init$; upb_Map* map = (upb_Map*)upb_Message_GetMap(UPB_UPCAST(msg), &field); if (!map) return; _upb_Map_Clear(map); } - )cc", - msg_name, resolved_name, FieldInitializer(pools, field, options)); - output( - R"cc( - UPB_INLINE bool $0_$1_set($0* msg, $2 key, $3 val, upb_Arena* a) { - const upb_MiniTableField field = $4; - upb_Map* map = _upb_Message_GetOrCreateMutableMap(UPB_UPCAST(msg), - &field, $5, $6, a); - return _upb_Map_Insert(map, &key, $5, &val, $6, a) != + + UPB_INLINE bool $msg_name$_$name$_set($msg_name$* msg, $key_type$ key, + $val_type$ val, upb_Arena* a) { + const upb_MiniTableField field = $field_init$; + upb_Map* map = _upb_Message_GetOrCreateMutableMap( + UPB_UPCAST(msg), &field, $key_size$, $val_size$, a); + return _upb_Map_Insert(map, &key, $key_size$, &val, $val_size$, a) != kUpb_MapInsertStatus_OutOfMemory; } - )cc", - msg_name, resolved_name, MapKeyCType(field), MapValueCType(field), - FieldInitializerStrong(pools, field, options), MapKeySize(field, "key"), - MapValueSize(field, "val")); - output( - R"cc( - UPB_INLINE bool $0_$1_delete($0* msg, $2 key) { - const upb_MiniTableField field = $3; + + UPB_INLINE bool $msg_name$_$name$_delete($msg_name$* msg, $key_type$ key) { + const upb_MiniTableField field = $field_init$; upb_Map* map = (upb_Map*)upb_Message_GetMap(UPB_UPCAST(msg), &field); if (!map) return false; - return _upb_Map_Delete(map, &key, $4, NULL); + return _upb_Map_Delete(map, &key, $key_size$, NULL); } - )cc", - msg_name, resolved_name, MapKeyCType(field), - FieldInitializer(pools, field, options), MapKeySize(field, "key")); + )cc"); } -void GenerateRepeatedSetters(upb::FieldDefPtr field, const DefPoolPair& pools, +void GenerateRepeatedSetters(Context& c, upb::FieldDefPtr field, absl::string_view msg_name, - const NameMangler& mangler, const Options& options, - Output& output) { - std::string resolved_name = mangler.ResolveFieldName(field.name()); - output( + const NameMangler& mangler) { + c.Emit( + { + {"ctype", CType(field)}, + {"msg_name", msg_name}, + {"name", mangler.ResolveFieldName(field.name())}, + {"field_init", FieldInitializerStrong(c.pools(), field, c.options())}, + }, R"cc( - UPB_INLINE $0* $1_mutable_$2($1* msg, size_t* size) { - upb_MiniTableField field = $3; + UPB_INLINE $ctype$* $msg_name$_mutable_$name$($msg_name$* msg, + size_t* size) { + upb_MiniTableField field = $field_init$; upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { if (size) *size = arr->UPB_PRIVATE(size); - return ($0*)upb_Array_MutableDataPtr(arr); + return ($ctype$*)upb_Array_MutableDataPtr(arr); } else { if (size) *size = 0; return NULL; } } - )cc", - CType(field), msg_name, resolved_name, - FieldInitializerStrong(pools, field, options)); - output( - R"cc( - UPB_INLINE $0* $1_resize_$2($1* msg, size_t size, upb_Arena* arena) { - upb_MiniTableField field = $3; - return ($0*)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + + UPB_INLINE $ctype$* $msg_name$_resize_$name$($msg_name$* msg, + size_t size, + upb_Arena* arena) { + upb_MiniTableField field = $field_init$; + return ($ctype$*)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } - )cc", - CType(field), msg_name, resolved_name, - FieldInitializer(pools, field, options)); + )cc"); + if (field.ctype() == kUpb_CType_Message) { - output( + c.Emit( + { + {"sub_ctype", MessageType(field.message_type())}, + {"msg_name", msg_name}, + {"name", mangler.ResolveFieldName(field.name())}, + {"sub_mini_table", + MessageMiniTableRef(field.message_type(), c.options())}, + {"field_init", + FieldInitializerStrong(c.pools(), field, c.options())}, + }, R"cc( - UPB_INLINE struct $0* $1_add_$2($1* msg, upb_Arena* arena) { - upb_MiniTableField field = $4; + UPB_INLINE struct $sub_ctype$* $msg_name$_add_$name$( + $msg_name$* msg, upb_Arena* arena) { + upb_MiniTableField field = $field_init$; upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); if (!arr || !UPB_PRIVATE(_upb_Array_ResizeUninitialized)( arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct $0* sub = (struct $0*)_upb_Message_New($3, arena); + struct $sub_ctype$* sub = + (struct $sub_ctype$*)_upb_Message_New($sub_mini_table$, arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); return sub; } - )cc", - MessageType(field.message_type()), msg_name, resolved_name, - MessageMiniTableRef(field.message_type(), options), - FieldInitializerStrong(pools, field, options)); + )cc"); } else { - output( + c.Emit( + {{"ctype", CType(field)}, + {"msg_name", msg_name}, + {"name", mangler.ResolveFieldName(field.name())}, + {"field_init", FieldInitializerStrong(c.pools(), field, c.options())}}, R"cc( - UPB_INLINE bool $1_add_$2($1* msg, $0 val, upb_Arena* arena) { - upb_MiniTableField field = $3; + UPB_INLINE bool $msg_name$_add_$name$($msg_name$* msg, $ctype$ val, + upb_Arena* arena) { + upb_MiniTableField field = $field_init$; upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); if (!arr || !UPB_PRIVATE(_upb_Array_ResizeUninitialized)( @@ -730,85 +814,84 @@ void GenerateRepeatedSetters(upb::FieldDefPtr field, const DefPoolPair& pools, (arr, arr->UPB_PRIVATE(size) - 1, &val, sizeof(val)); return true; } - )cc", - CType(field), msg_name, resolved_name, - FieldInitializerStrong(pools, field, options)); + )cc"); } } -void GenerateNonRepeatedSetters(upb::FieldDefPtr field, - const DefPoolPair& pools, +void GenerateNonRepeatedSetters(Context& c, upb::FieldDefPtr field, absl::string_view msg_name, - const NameMangler& mangler, - const Options& options, Output& output) { + const NameMangler& mangler) { std::string field_name = mangler.ResolveFieldName(field.name()); - output(R"cc( - UPB_INLINE void $0_set_$1($0 *msg, $2 value) { - const upb_MiniTableField field = $3; - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); - } - )cc", - msg_name, field_name, CType(field), - FieldInitializerStrong(pools, field, options)); + c.Emit( + {{"msg_name", msg_name}, + {"name", field_name}, + {"ctype", CType(field)}, + {"field_init", FieldInitializerStrong(c.pools(), field, c.options())}}, + R"cc( + UPB_INLINE void $msg_name$_set_$name$($msg_name$* msg, $ctype$ value) { + const upb_MiniTableField field = $field_init$; + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); + } + )cc"); // Message fields also have a Msg_mutable_foo() accessor that will create // the sub-message if it doesn't already exist. if (field.IsSubMessage()) { - output( - R"cc( - UPB_INLINE struct $0* $1_mutable_$2($1* msg, upb_Arena* arena) { - struct $0* sub = (struct $0*)$1_$2(msg); - if (sub == NULL) { - sub = (struct $0*)_upb_Message_New($3, arena); - if (sub) $1_set_$2(msg, sub); - } - return sub; - } - )cc", - MessageType(field.message_type()), msg_name, field_name, - MessageMiniTableRef(field.message_type(), options)); + c.Emit({{"sub_ctype", MessageType(field.message_type())}, + {"msg_name", msg_name}, + {"name", field_name}, + {"sub_mini_table", + MessageMiniTableRef(field.message_type(), c.options())}}, + R"cc( + UPB_INLINE struct $sub_ctype$* $msg_name$_mutable_$name$( + $msg_name$* msg, upb_Arena* arena) { + struct $sub_ctype$* sub = (struct $sub_ctype$*)$msg_name$_$name$(msg); + if (sub == NULL) { + sub = (struct $sub_ctype$*)_upb_Message_New($sub_mini_table$, arena); + if (sub) $msg_name$_set_$name$(msg, sub); + } + return sub; + } + )cc"); } } -void GenerateSetters(upb::FieldDefPtr field, const DefPoolPair& pools, - absl::string_view msg_name, const NameMangler& mangler, - const Options& options, Output& output) { +void GenerateSetters(Context& c, upb::FieldDefPtr field, + absl::string_view msg_name, const NameMangler& mangler) { if (field.IsMap()) { - GenerateMapSetters(field, pools, msg_name, mangler, options, output); + GenerateMapSetters(c, field, msg_name, mangler); } else if (field.IsSequence()) { - GenerateRepeatedSetters(field, pools, msg_name, mangler, options, output); + GenerateRepeatedSetters(c, field, msg_name, mangler); } else { - GenerateNonRepeatedSetters(field, pools, msg_name, mangler, options, - output); + GenerateNonRepeatedSetters(c, field, msg_name, mangler); } } -void GenerateMessageInHeader(upb::MessageDefPtr message, - const DefPoolPair& pools, const Options& options, - Output& output) { - output("/* $0 */\n\n", message.full_name()); +void GenerateMessageInHeader(Context& c, upb::MessageDefPtr message) { + c.Emit({{"fullname", message.full_name()}}, R"cc(/* $fullname$ */ + )cc"); std::string msg_name = MessageType(message); - GenerateMessageFunctionsInHeader(message, options, output); + GenerateMessageFunctionsInHeader(c, message); for (int i = 0; i < message.real_oneof_count(); i++) { - GenerateOneofInHeader(message.oneof(i), pools, msg_name, options, output); + GenerateOneofInHeader(c, message.oneof(i), msg_name); } NameMangler mangler(GetUpbFields(message)); for (auto field : FieldNumberOrder(message)) { - GenerateClear(field, pools, msg_name, mangler, options, output); - GenerateGetters(field, pools, msg_name, mangler, options, output); - GenerateHazzer(field, pools, msg_name, mangler, options, output); + GenerateClear(c, field, msg_name, mangler); + GenerateGetters(c, field, msg_name, mangler); + GenerateHazzer(c, field, msg_name, mangler); } - output("\n"); + c.Emit("\n"); for (auto field : FieldNumberOrder(message)) { - GenerateSetters(field, pools, msg_name, mangler, options, output); + GenerateSetters(c, field, msg_name, mangler); } - output("\n"); + c.Emit("\n"); } std::vector SortedForwardMessages( @@ -839,8 +922,9 @@ std::vector SortedForwardMessages( return ret; } -void WriteHeader(const DefPoolPair& pools, upb::FileDefPtr file, - const Options& options, Output& output) { +void WriteHeader(Context& c, upb::FileDefPtr file) { + const DefPoolPair& pools = c.pools(); + const Options& options = c.options(); const std::vector sorted_messages = SortedMessages(file); // Filter out map entries. @@ -855,97 +939,135 @@ void WriteHeader(const DefPoolPair& pools, upb::FileDefPtr file, std::vector forward_messages = SortedForwardMessages(this_file_messages, this_file_exts); - output(FileWarning(file.name())); - output( - "#ifndef $0_UPB_H_\n" - "#define $0_UPB_H_\n\n" - "#include \"upb/generated_code_support.h\"\n\n", - IncludeGuard(file.name())); + c.Emit(FileWarning(file.name())); + c.Emit({{"include_guard", IncludeGuard(file.name())}}, + R"cc(#ifndef $include_guard$_UPB_H_ +#define $include_guard$_UPB_H_ + +#include "upb/generated_code_support.h" + )cc"); for (int i = 0; i < file.public_dependency_count(); i++) { if (i == 0) { - output("/* Public Imports. */\n"); + c.Emit(R"cc(/* Public Imports. */ + )cc"); } - output("#include \"$0\"\n", - CApiHeaderFilename(file.public_dependency(i).name(), - options.bootstrap_stage >= 0)); + c.Emit({{"header", CApiHeaderFilename(file.public_dependency(i).name(), + options.bootstrap_stage >= 0)}}, + R"cc(#include "$header$" + )cc"); } if (file.public_dependency_count() > 0) { - output("\n"); + c.Emit("\n"); } if (options.bootstrap_stage != 0) { - output("#include \"$0\"\n\n", - MiniTableHeaderFilename(file.name(), options.bootstrap_stage >= 0)); + c.Emit({{"header", MiniTableHeaderFilename(file.name(), + options.bootstrap_stage >= 0)}}, + R"cc(#include "$header$" + )cc"); for (int i = 0; i < file.dependency_count(); i++) { if (options.strip_nonfunctional_codegen && google::protobuf::compiler::IsKnownFeatureProto(file.dependency(i).name())) { // Strip feature imports for editions codegen tests. continue; } - output("#include \"$0\"\n", - MiniTableHeaderFilename(file.dependency(i).name(), - options.bootstrap_stage >= 0)); + c.Emit( + {{"header", MiniTableHeaderFilename(file.dependency(i).name(), + options.bootstrap_stage >= 0)}}, + R"cc(#include "$header$" + )cc"); } - output("\n"); + c.Emit("\n"); } - output( - "// Must be last.\n" - "#include \"upb/port/def.inc\"\n" - "\n" - "#ifdef __cplusplus\n" - "extern \"C\" {\n" - "#endif\n" - "\n"); + c.Emit(R"cc( + // Must be last. +#include "upb/port/def.inc" + +#ifdef __cplusplus + extern "C" { +#endif + )cc"); if (options.bootstrap_stage == 0) { for (auto message : this_file_messages) { - output("extern const upb_MiniTable* $0(void);\n", - MiniTableMessageVarName(message.full_name())); + c.Emit( + { + {"name", MiniTableMessageVarName(message.full_name())}, + }, + R"cc( + extern const upb_MiniTable* $name$(void); + )cc"); } for (auto message : forward_messages) { - output("extern const upb_MiniTable* $0(void);\n", - MiniTableMessageVarName(message.full_name())); + c.Emit( + { + {"name", MiniTableMessageVarName(message.full_name())}, + }, + R"cc( + extern const upb_MiniTable* $name$(void); + )cc"); } for (auto enumdesc : this_file_enums) { - output("extern const upb_MiniTableEnum* $0(void);\n", - MiniTableEnumVarName(enumdesc.full_name())); + c.Emit( + { + {"name", MiniTableEnumVarName(enumdesc.full_name())}, + }, + R"cc( + extern const upb_MiniTableEnum* $name$(void); + )cc"); } - output("\n"); + c.Emit("\n"); } // Forward-declare types defined in this file. for (auto message : this_file_messages) { - output("typedef struct $0 { upb_Message UPB_PRIVATE(base); } $0;\n", - MessageType(message)); + c.Emit( + { + {"msg_type", MessageType(message)}, + }, + R"cc( + typedef struct $msg_type$ { + upb_Message UPB_PRIVATE(base); + } $msg_type$; + )cc"); + c.Emit("\n"); } // Forward-declare types not in this file, but used as submessages. // Order by full name for consistent ordering. for (auto msg : forward_messages) { - output("struct $0;\n", MessageType(msg)); + c.Emit({{"msg_type", MessageType(msg)}}, R"cc(struct $msg_type$; + )cc"); } if (!this_file_messages.empty()) { - output("\n"); + c.Emit("\n"); } for (auto enumdesc : this_file_enums) { - output("typedef enum {\n"); - DumpEnumValues(enumdesc, output); - output("} $0;\n\n", EnumType(enumdesc)); + c.Emit({{"enum_type", EnumType(enumdesc)}, + Sub("enum_values", [&] { DumpEnumValues(c, enumdesc); })}, + // Avoiding R"cc( here because clang-format does really weird things + // with it. + R"( + typedef enum { + $enum_values$; + } $enum_type$; + )"); + c.Emit("\n"); } - output("\n"); + c.Emit("\n"); - output("\n"); + c.Emit("\n"); for (auto message : this_file_messages) { - GenerateMessageInHeader(message, pools, options, output); + GenerateMessageInHeader(c, message); } for (auto ext : this_file_exts) { - GenerateExtensionInHeader(pools, ext, options, output); + GenerateExtensionInHeader(c, ext); } if (absl::string_view(file.name()) == "google/protobuf/descriptor.proto" || @@ -972,20 +1094,29 @@ void WriteHeader(const DefPoolPair& pools, upb::FileDefPtr file, } } - output("/* Max size 32 is $0 */\n", max32_message.full_name()); - output("/* Max size 64 is $0 */\n", max64_message.full_name()); - output("#define _UPB_MAXOPT_SIZE UPB_SIZE($0, $1)\n\n", max32, max64); + c.Emit( + { + {"max_name_32", max32_message.full_name()}, + {"max_name_64", max64_message.full_name()}, + {"max_size_32", absl::StrCat(max32)}, + {"max_size_64", absl::StrCat(max64)}, + }, + R"( + /* Max size 32 is $max_name_32$ */ + /* Max size 64 is $max_name_64$ */ + #define _UPB_MAXOPT_SIZE UPB_SIZE($max_size_32$, $max_size_64$) + )"); } - output( - "#ifdef __cplusplus\n" - "} /* extern \"C\" */\n" - "#endif\n" - "\n" - "#include \"upb/port/undef.inc\"\n" - "\n" - "#endif /* $0_UPB_H_ */\n", - IncludeGuard(file.name())); + c.Emit({{"include_guard", IncludeGuard(file.name())}}, + R"cc(#ifdef __cplusplus + } /* extern "C" */ +#endif + +#include "upb/port/undef.inc" + +#endif /* $include_guard$_UPB_H_ */ + )cc"); } std::string FieldInitializer(upb::FieldDefPtr field, @@ -1034,90 +1165,98 @@ std::string FieldInitializer(const DefPoolPair& pools, upb::FieldDefPtr field, pools.GetField32(field), options); } -void WriteMessageMiniDescriptorInitializer(upb::MessageDefPtr msg, - const Options& options, - Output& output) { - Output resolve_calls; +void WriteResolveCalls(Context& c, upb::MessageDefPtr msg) { for (int i = 0; i < msg.field_count(); i++) { upb::FieldDefPtr field = msg.field(i); if (!field.message_type() && !field.enum_subdef()) continue; if (field.message_type()) { - resolve_calls( - "upb_MiniTable_SetSubMessage(mini_table, " - "(upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, " - "$0), $1);\n ", - field.number(), MessageMiniTableRef(field.message_type(), options)); + c.Emit( + {{"number", absl::StrCat(field.number())}, + {"msg_mini_table", + MessageMiniTableRef(field.message_type(), c.options())}}, + R"cc( + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + $number$), + $msg_mini_table$); + )cc"); } else if (field.enum_subdef() && field.enum_subdef().is_closed()) { - resolve_calls( - "upb_MiniTable_SetSubEnum(mini_table, " - "(upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, " - "$0), $1);\n ", - field.number(), EnumMiniTableRef(field.enum_subdef(), options)); + c.Emit( + {{"number", absl::StrCat(field.number())}, + {"enum_mini_table", + EnumMiniTableRef(field.enum_subdef(), c.options())}}, + R"cc( + upb_MiniTable_SetSubEnum( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + $number$), + $enum_mini_table$); + )cc"); } } +} - output( - R"cc( - const upb_MiniTable* $0() { - static upb_MiniTable* mini_table = NULL; - static const char* mini_descriptor = "$1"; - if (mini_table) return mini_table; - upb_Status status; - mini_table = - upb_MiniTable_Build(mini_descriptor, strlen(mini_descriptor), - upb_BootstrapArena(), &status); - if (!mini_table) { - fprintf(stderr, "Failed to build mini_table for $0: %s\n", - upb_Status_ErrorMessage(&status)); - abort(); - } - $2return mini_table; - } - )cc", - MiniTableMessageVarName(msg.full_name()), msg.MiniDescriptorEncode(), - resolve_calls.output()); - output("\n"); +void WriteMessageMiniDescriptorInitializer(Context& c, upb::MessageDefPtr msg) { + c.Emit({{"name", MiniTableMessageVarName(msg.full_name())}, + {"mini_descriptor", msg.MiniDescriptorEncode()}, + {"resolve_calls", [&] { WriteResolveCalls(c, msg); }}}, + R"cc( + const upb_MiniTable* $name$() { + static upb_MiniTable* mini_table = NULL; + static const char* mini_descriptor = "$mini_descriptor$"; + if (mini_table) return mini_table; + upb_Status status; + mini_table = + upb_MiniTable_Build(mini_descriptor, strlen(mini_descriptor), + upb_BootstrapArena(), &status); + if (!mini_table) { + fprintf(stderr, "Failed to build mini_table for $name$: %s\n", + upb_Status_ErrorMessage(&status)); + abort(); + } + $resolve_calls$ return mini_table; + } + )cc"); + c.Emit("\n"); } -void WriteEnumMiniDescriptorInitializer(upb::EnumDefPtr enum_def, - const Options& options, - Output& output) { - output( - R"cc( - const upb_MiniTableEnum* $0() { - static const upb_MiniTableEnum* mini_table = NULL; - static const char* mini_descriptor = "$1"; - if (mini_table) return mini_table; - mini_table = - upb_MiniTableEnum_Build(mini_descriptor, strlen(mini_descriptor), - upb_BootstrapArena(), NULL); - return mini_table; - } - )cc", - MiniTableEnumVarName(enum_def.full_name()), - enum_def.MiniDescriptorEncode()); - output("\n"); +void WriteEnumMiniDescriptorInitializer(Context& c, upb::EnumDefPtr enum_def) { + c.Emit({{"name", MiniTableEnumVarName(enum_def.full_name())}, + {"mini_descriptor", enum_def.MiniDescriptorEncode()}}, + R"cc( + const upb_MiniTableEnum* $name$() { + static const upb_MiniTableEnum* mini_table = NULL; + static const char* mini_descriptor = "$mini_descriptor$"; + if (mini_table) return mini_table; + mini_table = upb_MiniTableEnum_Build(mini_descriptor, + strlen(mini_descriptor), + upb_BootstrapArena(), NULL); + return mini_table; + } + )cc"); + c.Emit("\n"); } -void WriteMiniDescriptorSource(const DefPoolPair& pools, upb::FileDefPtr file, - const Options& options, Output& output) { - output( - "#include \n" - "#include \"upb/generated_code_support.h\"\n" - "#include \"$0\"\n\n", - CApiHeaderFilename(file.name(), options.bootstrap_stage >= 0)); +void WriteMiniDescriptorSource(Context& c, upb::FileDefPtr file) { + const Options& options = c.options(); + c.Emit({{"header", + CApiHeaderFilename(file.name(), options.bootstrap_stage >= 0)}}, + "#include \n" + "#include \"upb/generated_code_support.h\"\n" + "#include \"$header$\"\n\n"); for (int i = 0; i < file.dependency_count(); i++) { if (options.strip_nonfunctional_codegen && google::protobuf::compiler::IsKnownFeatureProto(file.dependency(i).name())) { continue; } - output("#include \"$0\"\n", - CApiHeaderFilename(file.dependency(i).name(), - options.bootstrap_stage >= 0)); + c.Emit({{"header", CApiHeaderFilename(file.dependency(i).name(), + options.bootstrap_stage >= 0)}}, + "#include \"$header$\"\n"); } - output( + c.Emit( R"cc( static upb_Arena* upb_BootstrapArena() { static upb_Arena* arena = NULL; @@ -1126,33 +1265,33 @@ void WriteMiniDescriptorSource(const DefPoolPair& pools, upb::FileDefPtr file, } )cc"); - output("\n"); + c.Emit("\n"); for (const auto msg : SortedMessages(file)) { - WriteMessageMiniDescriptorInitializer(msg, options, output); + WriteMessageMiniDescriptorInitializer(c, msg); } for (const auto msg : SortedEnums(file, kClosedEnums)) { - WriteEnumMiniDescriptorInitializer(msg, options, output); + WriteEnumMiniDescriptorInitializer(c, msg); } } void GenerateFile(const DefPoolPair& pools, upb::FileDefPtr file, const Options& options, google::protobuf::compiler::GeneratorContext* context) { - Output h_output; - WriteHeader(pools, file, options, h_output); { auto stream = absl::WrapUnique(context->Open(CApiHeaderFilename(file.name(), false))); - ABSL_CHECK(stream->WriteCord(absl::Cord(h_output.output()))); + google::protobuf::io::Printer printer(stream.get()); + Context c(pools, options, printer); + WriteHeader(c, file); } if (options.bootstrap_stage == 0) { - Output c_output; - WriteMiniDescriptorSource(pools, file, options, c_output); auto stream = absl::WrapUnique(context->Open(SourceFilename(file))); - ABSL_CHECK(stream->WriteCord(absl::Cord(c_output.output()))); + google::protobuf::io::Printer printer(stream.get()); + Context c(pools, options, printer); + WriteMiniDescriptorSource(c, file); } else { // TODO: remove once we can figure out how to make both Blaze // and Bazel happy with header-only libraries. diff --git a/upb_generator/stage0/google/protobuf/compiler/plugin.upb.c b/upb_generator/stage0/google/protobuf/compiler/plugin.upb.c index 079baca5186f2..d03634865bcbd 100644 --- a/upb_generator/stage0/google/protobuf/compiler/plugin.upb.c +++ b/upb_generator/stage0/google/protobuf/compiler/plugin.upb.c @@ -22,7 +22,7 @@ const upb_MiniTable* google__protobuf__compiler__Version_msg_init() { upb_Status_ErrorMessage(&status)); abort(); } - return mini_table; + return mini_table; } const upb_MiniTable* google__protobuf__compiler__CodeGeneratorRequest_msg_init() { @@ -38,10 +38,22 @@ const upb_MiniTable* google__protobuf__compiler__CodeGeneratorRequest_msg_init() upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 15), google__protobuf__FileDescriptorProto_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 17), google__protobuf__FileDescriptorProto_msg_init()); - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 3), google__protobuf__compiler__Version_msg_init()); - return mini_table; + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 15), + google__protobuf__FileDescriptorProto_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 17), + google__protobuf__FileDescriptorProto_msg_init()); + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 3), + google__protobuf__compiler__Version_msg_init()); + return mini_table; } const upb_MiniTable* google__protobuf__compiler__CodeGeneratorResponse_msg_init() { @@ -57,8 +69,12 @@ const upb_MiniTable* google__protobuf__compiler__CodeGeneratorResponse_msg_init( upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 15), google__protobuf__compiler__CodeGeneratorResponse__File_msg_init()); - return mini_table; + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 15), + google__protobuf__compiler__CodeGeneratorResponse__File_msg_init()); + return mini_table; } const upb_MiniTable* google__protobuf__compiler__CodeGeneratorResponse__File_msg_init() { @@ -74,17 +90,21 @@ const upb_MiniTable* google__protobuf__compiler__CodeGeneratorResponse__File_msg upb_Status_ErrorMessage(&status)); abort(); } - upb_MiniTable_SetSubMessage(mini_table, (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, 16), google__protobuf__GeneratedCodeInfo_msg_init()); - return mini_table; + upb_MiniTable_SetSubMessage( + mini_table, + (upb_MiniTableField*)upb_MiniTable_FindFieldByNumber(mini_table, + 16), + google__protobuf__GeneratedCodeInfo_msg_init()); + return mini_table; } const upb_MiniTableEnum* google__protobuf__compiler__CodeGeneratorResponse__Feature_enum_init() { static const upb_MiniTableEnum* mini_table = NULL; static const char* mini_descriptor = "!)"; if (mini_table) return mini_table; - mini_table = - upb_MiniTableEnum_Build(mini_descriptor, strlen(mini_descriptor), - upb_BootstrapArena(), NULL); + mini_table = upb_MiniTableEnum_Build(mini_descriptor, + strlen(mini_descriptor), + upb_BootstrapArena(), NULL); return mini_table; } diff --git a/upb_generator/stage0/google/protobuf/compiler/plugin.upb.h b/upb_generator/stage0/google/protobuf/compiler/plugin.upb.h index a6a5baed8fa90..b2536321e067a 100644 --- a/upb_generator/stage0/google/protobuf/compiler/plugin.upb.h +++ b/upb_generator/stage0/google/protobuf/compiler/plugin.upb.h @@ -10,14 +10,12 @@ #define GOOGLE_PROTOBUF_COMPILER_PLUGIN_PROTO_UPB_H__UPB_H_ #include "upb/generated_code_support.h" - // Must be last. #include "upb/port/def.inc" #ifdef __cplusplus extern "C" { #endif - extern const upb_MiniTable* google__protobuf__compiler__Version_msg_init(void); extern const upb_MiniTable* google__protobuf__compiler__CodeGeneratorRequest_msg_init(void); extern const upb_MiniTable* google__protobuf__compiler__CodeGeneratorResponse_msg_init(void); @@ -26,10 +24,22 @@ extern const upb_MiniTable* google__protobuf__FileDescriptorProto_msg_init(void) extern const upb_MiniTable* google__protobuf__GeneratedCodeInfo_msg_init(void); extern const upb_MiniTableEnum* google__protobuf__compiler__CodeGeneratorResponse__Feature_enum_init(void); -typedef struct google_protobuf_compiler_Version { upb_Message UPB_PRIVATE(base); } google_protobuf_compiler_Version; -typedef struct google_protobuf_compiler_CodeGeneratorRequest { upb_Message UPB_PRIVATE(base); } google_protobuf_compiler_CodeGeneratorRequest; -typedef struct google_protobuf_compiler_CodeGeneratorResponse { upb_Message UPB_PRIVATE(base); } google_protobuf_compiler_CodeGeneratorResponse; -typedef struct google_protobuf_compiler_CodeGeneratorResponse_File { upb_Message UPB_PRIVATE(base); } google_protobuf_compiler_CodeGeneratorResponse_File; +typedef struct google_protobuf_compiler_Version { + upb_Message UPB_PRIVATE(base); +} google_protobuf_compiler_Version; + +typedef struct google_protobuf_compiler_CodeGeneratorRequest { + upb_Message UPB_PRIVATE(base); +} google_protobuf_compiler_CodeGeneratorRequest; + +typedef struct google_protobuf_compiler_CodeGeneratorResponse { + upb_Message UPB_PRIVATE(base); +} google_protobuf_compiler_CodeGeneratorResponse; + +typedef struct google_protobuf_compiler_CodeGeneratorResponse_File { + upb_Message UPB_PRIVATE(base); +} google_protobuf_compiler_CodeGeneratorResponse_File; + struct google_protobuf_FileDescriptorProto; struct google_protobuf_GeneratedCodeInfo; @@ -42,37 +52,39 @@ typedef enum { /* google.protobuf.compiler.Version */ - UPB_INLINE google_protobuf_compiler_Version* google_protobuf_compiler_Version_new(upb_Arena* arena) { return (google_protobuf_compiler_Version*)_upb_Message_New(google__protobuf__compiler__Version_msg_init(), arena); } -UPB_INLINE google_protobuf_compiler_Version* google_protobuf_compiler_Version_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_compiler_Version* google_protobuf_compiler_Version_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_compiler_Version* ret = google_protobuf_compiler_Version_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__compiler__Version_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__compiler__Version_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_compiler_Version* google_protobuf_compiler_Version_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_compiler_Version* google_protobuf_compiler_Version_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_compiler_Version* ret = google_protobuf_compiler_Version_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__compiler__Version_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__compiler__Version_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_compiler_Version_serialize(const google_protobuf_compiler_Version* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_compiler_Version_serialize(const google_protobuf_compiler_Version* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__compiler__Version_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_compiler_Version_serialize_ex(const google_protobuf_compiler_Version* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_compiler_Version_serialize_ex(const google_protobuf_compiler_Version* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__compiler__Version_msg_init(), options, arena, &ptr, len); return ptr; @@ -142,55 +154,57 @@ UPB_INLINE bool google_protobuf_compiler_Version_has_suffix(const google_protobu return upb_Message_HasBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE void google_protobuf_compiler_Version_set_major(google_protobuf_compiler_Version *msg, int32_t value) { +UPB_INLINE void google_protobuf_compiler_Version_set_major(google_protobuf_compiler_Version* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__Version_msg_init(), 1); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_compiler_Version_set_minor(google_protobuf_compiler_Version *msg, int32_t value) { +UPB_INLINE void google_protobuf_compiler_Version_set_minor(google_protobuf_compiler_Version* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__Version_msg_init(), 2); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_compiler_Version_set_patch(google_protobuf_compiler_Version *msg, int32_t value) { +UPB_INLINE void google_protobuf_compiler_Version_set_patch(google_protobuf_compiler_Version* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__Version_msg_init(), 3); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_compiler_Version_set_suffix(google_protobuf_compiler_Version *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_compiler_Version_set_suffix(google_protobuf_compiler_Version* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__Version_msg_init(), 4); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } /* google.protobuf.compiler.CodeGeneratorRequest */ - UPB_INLINE google_protobuf_compiler_CodeGeneratorRequest* google_protobuf_compiler_CodeGeneratorRequest_new(upb_Arena* arena) { return (google_protobuf_compiler_CodeGeneratorRequest*)_upb_Message_New(google__protobuf__compiler__CodeGeneratorRequest_msg_init(), arena); } -UPB_INLINE google_protobuf_compiler_CodeGeneratorRequest* google_protobuf_compiler_CodeGeneratorRequest_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_compiler_CodeGeneratorRequest* google_protobuf_compiler_CodeGeneratorRequest_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_compiler_CodeGeneratorRequest* ret = google_protobuf_compiler_CodeGeneratorRequest_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__compiler__CodeGeneratorRequest_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__compiler__CodeGeneratorRequest_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_compiler_CodeGeneratorRequest* google_protobuf_compiler_CodeGeneratorRequest_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_compiler_CodeGeneratorRequest* google_protobuf_compiler_CodeGeneratorRequest_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_compiler_CodeGeneratorRequest* ret = google_protobuf_compiler_CodeGeneratorRequest_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__compiler__CodeGeneratorRequest_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__compiler__CodeGeneratorRequest_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_compiler_CodeGeneratorRequest_serialize(const google_protobuf_compiler_CodeGeneratorRequest* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_compiler_CodeGeneratorRequest_serialize(const google_protobuf_compiler_CodeGeneratorRequest* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__compiler__CodeGeneratorRequest_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_compiler_CodeGeneratorRequest_serialize_ex(const google_protobuf_compiler_CodeGeneratorRequest* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_compiler_CodeGeneratorRequest_serialize_ex(const google_protobuf_compiler_CodeGeneratorRequest* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__compiler__CodeGeneratorRequest_msg_init(), options, arena, &ptr, len); return ptr; @@ -199,7 +213,8 @@ UPB_INLINE void google_protobuf_compiler_CodeGeneratorRequest_clear_file_to_gene const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorRequest_msg_init(), 1); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE upb_StringView const* google_protobuf_compiler_CodeGeneratorRequest_file_to_generate(const google_protobuf_compiler_CodeGeneratorRequest* msg, size_t* size) { +UPB_INLINE upb_StringView const* google_protobuf_compiler_CodeGeneratorRequest_file_to_generate(const google_protobuf_compiler_CodeGeneratorRequest* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorRequest_msg_init(), 1); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -210,7 +225,10 @@ UPB_INLINE upb_StringView const* google_protobuf_compiler_CodeGeneratorRequest_f return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_compiler_CodeGeneratorRequest_file_to_generate_upb_array(const google_protobuf_compiler_CodeGeneratorRequest* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_compiler_CodeGeneratorRequest_file_to_generate_upb_array( + const google_protobuf_compiler_CodeGeneratorRequest* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorRequest_msg_init(), 1); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -218,7 +236,9 @@ UPB_INLINE const upb_Array* _google_protobuf_compiler_CodeGeneratorRequest_file_ } return arr; } -UPB_INLINE upb_Array* _google_protobuf_compiler_CodeGeneratorRequest_file_to_generate_mutable_upb_array(google_protobuf_compiler_CodeGeneratorRequest* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_compiler_CodeGeneratorRequest_file_to_generate_mutable_upb_array( + google_protobuf_compiler_CodeGeneratorRequest* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorRequest_msg_init(), 1); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -263,7 +283,8 @@ UPB_INLINE void google_protobuf_compiler_CodeGeneratorRequest_clear_proto_file(g const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorRequest_msg_init(), 15); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const struct google_protobuf_FileDescriptorProto* const* google_protobuf_compiler_CodeGeneratorRequest_proto_file(const google_protobuf_compiler_CodeGeneratorRequest* msg, size_t* size) { +UPB_INLINE const struct google_protobuf_FileDescriptorProto* const* google_protobuf_compiler_CodeGeneratorRequest_proto_file(const google_protobuf_compiler_CodeGeneratorRequest* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorRequest_msg_init(), 15); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -274,7 +295,10 @@ UPB_INLINE const struct google_protobuf_FileDescriptorProto* const* google_proto return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_compiler_CodeGeneratorRequest_proto_file_upb_array(const google_protobuf_compiler_CodeGeneratorRequest* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_compiler_CodeGeneratorRequest_proto_file_upb_array( + const google_protobuf_compiler_CodeGeneratorRequest* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorRequest_msg_init(), 15); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -282,7 +306,9 @@ UPB_INLINE const upb_Array* _google_protobuf_compiler_CodeGeneratorRequest_proto } return arr; } -UPB_INLINE upb_Array* _google_protobuf_compiler_CodeGeneratorRequest_proto_file_mutable_upb_array(google_protobuf_compiler_CodeGeneratorRequest* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_compiler_CodeGeneratorRequest_proto_file_mutable_upb_array( + google_protobuf_compiler_CodeGeneratorRequest* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorRequest_msg_init(), 15); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -295,7 +321,8 @@ UPB_INLINE void google_protobuf_compiler_CodeGeneratorRequest_clear_source_file_ const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorRequest_msg_init(), 17); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const struct google_protobuf_FileDescriptorProto* const* google_protobuf_compiler_CodeGeneratorRequest_source_file_descriptors(const google_protobuf_compiler_CodeGeneratorRequest* msg, size_t* size) { +UPB_INLINE const struct google_protobuf_FileDescriptorProto* const* google_protobuf_compiler_CodeGeneratorRequest_source_file_descriptors(const google_protobuf_compiler_CodeGeneratorRequest* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorRequest_msg_init(), 17); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -306,7 +333,10 @@ UPB_INLINE const struct google_protobuf_FileDescriptorProto* const* google_proto return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_compiler_CodeGeneratorRequest_source_file_descriptors_upb_array(const google_protobuf_compiler_CodeGeneratorRequest* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_compiler_CodeGeneratorRequest_source_file_descriptors_upb_array( + const google_protobuf_compiler_CodeGeneratorRequest* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorRequest_msg_init(), 17); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -314,7 +344,9 @@ UPB_INLINE const upb_Array* _google_protobuf_compiler_CodeGeneratorRequest_sourc } return arr; } -UPB_INLINE upb_Array* _google_protobuf_compiler_CodeGeneratorRequest_source_file_descriptors_mutable_upb_array(google_protobuf_compiler_CodeGeneratorRequest* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_compiler_CodeGeneratorRequest_source_file_descriptors_mutable_upb_array( + google_protobuf_compiler_CodeGeneratorRequest* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorRequest_msg_init(), 17); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -324,7 +356,8 @@ UPB_INLINE upb_Array* _google_protobuf_compiler_CodeGeneratorRequest_source_file return arr; } -UPB_INLINE upb_StringView* google_protobuf_compiler_CodeGeneratorRequest_mutable_file_to_generate(google_protobuf_compiler_CodeGeneratorRequest* msg, size_t* size) { +UPB_INLINE upb_StringView* google_protobuf_compiler_CodeGeneratorRequest_mutable_file_to_generate(google_protobuf_compiler_CodeGeneratorRequest* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorRequest_msg_init(), 1); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -335,12 +368,16 @@ UPB_INLINE upb_StringView* google_protobuf_compiler_CodeGeneratorRequest_mutable return NULL; } } -UPB_INLINE upb_StringView* google_protobuf_compiler_CodeGeneratorRequest_resize_file_to_generate(google_protobuf_compiler_CodeGeneratorRequest* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE upb_StringView* google_protobuf_compiler_CodeGeneratorRequest_resize_file_to_generate(google_protobuf_compiler_CodeGeneratorRequest* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorRequest_msg_init(), 1); - return (upb_StringView*)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (upb_StringView*)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE bool google_protobuf_compiler_CodeGeneratorRequest_add_file_to_generate(google_protobuf_compiler_CodeGeneratorRequest* msg, upb_StringView val, upb_Arena* arena) { +UPB_INLINE bool google_protobuf_compiler_CodeGeneratorRequest_add_file_to_generate(google_protobuf_compiler_CodeGeneratorRequest* msg, upb_StringView val, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorRequest_msg_init(), 1); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -352,15 +389,16 @@ UPB_INLINE bool google_protobuf_compiler_CodeGeneratorRequest_add_file_to_genera (arr, arr->UPB_PRIVATE(size) - 1, &val, sizeof(val)); return true; } -UPB_INLINE void google_protobuf_compiler_CodeGeneratorRequest_set_parameter(google_protobuf_compiler_CodeGeneratorRequest *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_compiler_CodeGeneratorRequest_set_parameter(google_protobuf_compiler_CodeGeneratorRequest* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorRequest_msg_init(), 2); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_compiler_CodeGeneratorRequest_set_compiler_version(google_protobuf_compiler_CodeGeneratorRequest *msg, google_protobuf_compiler_Version* value) { +UPB_INLINE void google_protobuf_compiler_CodeGeneratorRequest_set_compiler_version(google_protobuf_compiler_CodeGeneratorRequest* msg, google_protobuf_compiler_Version* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorRequest_msg_init(), 3); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_compiler_Version* google_protobuf_compiler_CodeGeneratorRequest_mutable_compiler_version(google_protobuf_compiler_CodeGeneratorRequest* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_compiler_Version* google_protobuf_compiler_CodeGeneratorRequest_mutable_compiler_version( + google_protobuf_compiler_CodeGeneratorRequest* msg, upb_Arena* arena) { struct google_protobuf_compiler_Version* sub = (struct google_protobuf_compiler_Version*)google_protobuf_compiler_CodeGeneratorRequest_compiler_version(msg); if (sub == NULL) { sub = (struct google_protobuf_compiler_Version*)_upb_Message_New(google__protobuf__compiler__Version_msg_init(), arena); @@ -368,7 +406,8 @@ UPB_INLINE struct google_protobuf_compiler_Version* google_protobuf_compiler_Cod } return sub; } -UPB_INLINE struct google_protobuf_FileDescriptorProto** google_protobuf_compiler_CodeGeneratorRequest_mutable_proto_file(google_protobuf_compiler_CodeGeneratorRequest* msg, size_t* size) { +UPB_INLINE struct google_protobuf_FileDescriptorProto** google_protobuf_compiler_CodeGeneratorRequest_mutable_proto_file(google_protobuf_compiler_CodeGeneratorRequest* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorRequest_msg_init(), 15); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -379,12 +418,16 @@ UPB_INLINE struct google_protobuf_FileDescriptorProto** google_protobuf_compiler return NULL; } } -UPB_INLINE struct google_protobuf_FileDescriptorProto** google_protobuf_compiler_CodeGeneratorRequest_resize_proto_file(google_protobuf_compiler_CodeGeneratorRequest* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE struct google_protobuf_FileDescriptorProto** google_protobuf_compiler_CodeGeneratorRequest_resize_proto_file(google_protobuf_compiler_CodeGeneratorRequest* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorRequest_msg_init(), 15); - return (struct google_protobuf_FileDescriptorProto**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (struct google_protobuf_FileDescriptorProto**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_FileDescriptorProto* google_protobuf_compiler_CodeGeneratorRequest_add_proto_file(google_protobuf_compiler_CodeGeneratorRequest* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_FileDescriptorProto* google_protobuf_compiler_CodeGeneratorRequest_add_proto_file( + google_protobuf_compiler_CodeGeneratorRequest* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorRequest_msg_init(), 15); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -392,13 +435,15 @@ UPB_INLINE struct google_protobuf_FileDescriptorProto* google_protobuf_compiler_ arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_FileDescriptorProto* sub = (struct google_protobuf_FileDescriptorProto*)_upb_Message_New(google__protobuf__FileDescriptorProto_msg_init(), arena); + struct google_protobuf_FileDescriptorProto* sub = + (struct google_protobuf_FileDescriptorProto*)_upb_Message_New(google__protobuf__FileDescriptorProto_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); return sub; } -UPB_INLINE struct google_protobuf_FileDescriptorProto** google_protobuf_compiler_CodeGeneratorRequest_mutable_source_file_descriptors(google_protobuf_compiler_CodeGeneratorRequest* msg, size_t* size) { +UPB_INLINE struct google_protobuf_FileDescriptorProto** google_protobuf_compiler_CodeGeneratorRequest_mutable_source_file_descriptors(google_protobuf_compiler_CodeGeneratorRequest* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorRequest_msg_init(), 17); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -409,12 +454,16 @@ UPB_INLINE struct google_protobuf_FileDescriptorProto** google_protobuf_compiler return NULL; } } -UPB_INLINE struct google_protobuf_FileDescriptorProto** google_protobuf_compiler_CodeGeneratorRequest_resize_source_file_descriptors(google_protobuf_compiler_CodeGeneratorRequest* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE struct google_protobuf_FileDescriptorProto** google_protobuf_compiler_CodeGeneratorRequest_resize_source_file_descriptors(google_protobuf_compiler_CodeGeneratorRequest* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorRequest_msg_init(), 17); - return (struct google_protobuf_FileDescriptorProto**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (struct google_protobuf_FileDescriptorProto**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_FileDescriptorProto* google_protobuf_compiler_CodeGeneratorRequest_add_source_file_descriptors(google_protobuf_compiler_CodeGeneratorRequest* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_FileDescriptorProto* google_protobuf_compiler_CodeGeneratorRequest_add_source_file_descriptors( + google_protobuf_compiler_CodeGeneratorRequest* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorRequest_msg_init(), 17); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -422,7 +471,8 @@ UPB_INLINE struct google_protobuf_FileDescriptorProto* google_protobuf_compiler_ arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_FileDescriptorProto* sub = (struct google_protobuf_FileDescriptorProto*)_upb_Message_New(google__protobuf__FileDescriptorProto_msg_init(), arena); + struct google_protobuf_FileDescriptorProto* sub = + (struct google_protobuf_FileDescriptorProto*)_upb_Message_New(google__protobuf__FileDescriptorProto_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); @@ -430,37 +480,39 @@ UPB_INLINE struct google_protobuf_FileDescriptorProto* google_protobuf_compiler_ } /* google.protobuf.compiler.CodeGeneratorResponse */ - UPB_INLINE google_protobuf_compiler_CodeGeneratorResponse* google_protobuf_compiler_CodeGeneratorResponse_new(upb_Arena* arena) { return (google_protobuf_compiler_CodeGeneratorResponse*)_upb_Message_New(google__protobuf__compiler__CodeGeneratorResponse_msg_init(), arena); } -UPB_INLINE google_protobuf_compiler_CodeGeneratorResponse* google_protobuf_compiler_CodeGeneratorResponse_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_compiler_CodeGeneratorResponse* google_protobuf_compiler_CodeGeneratorResponse_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_compiler_CodeGeneratorResponse* ret = google_protobuf_compiler_CodeGeneratorResponse_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__compiler__CodeGeneratorResponse_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__compiler__CodeGeneratorResponse_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_compiler_CodeGeneratorResponse* google_protobuf_compiler_CodeGeneratorResponse_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_compiler_CodeGeneratorResponse* google_protobuf_compiler_CodeGeneratorResponse_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_compiler_CodeGeneratorResponse* ret = google_protobuf_compiler_CodeGeneratorResponse_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__compiler__CodeGeneratorResponse_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__compiler__CodeGeneratorResponse_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_compiler_CodeGeneratorResponse_serialize(const google_protobuf_compiler_CodeGeneratorResponse* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_compiler_CodeGeneratorResponse_serialize(const google_protobuf_compiler_CodeGeneratorResponse* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__compiler__CodeGeneratorResponse_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_compiler_CodeGeneratorResponse_serialize_ex(const google_protobuf_compiler_CodeGeneratorResponse* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_compiler_CodeGeneratorResponse_serialize_ex(const google_protobuf_compiler_CodeGeneratorResponse* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__compiler__CodeGeneratorResponse_msg_init(), options, arena, &ptr, len); return ptr; @@ -533,7 +585,8 @@ UPB_INLINE void google_protobuf_compiler_CodeGeneratorResponse_clear_file(google const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorResponse_msg_init(), 15); upb_Message_ClearBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE const google_protobuf_compiler_CodeGeneratorResponse_File* const* google_protobuf_compiler_CodeGeneratorResponse_file(const google_protobuf_compiler_CodeGeneratorResponse* msg, size_t* size) { +UPB_INLINE const google_protobuf_compiler_CodeGeneratorResponse_File* const* google_protobuf_compiler_CodeGeneratorResponse_file(const google_protobuf_compiler_CodeGeneratorResponse* msg, + size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorResponse_msg_init(), 15); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (arr) { @@ -544,7 +597,10 @@ UPB_INLINE const google_protobuf_compiler_CodeGeneratorResponse_File* const* goo return NULL; } } -UPB_INLINE const upb_Array* _google_protobuf_compiler_CodeGeneratorResponse_file_upb_array(const google_protobuf_compiler_CodeGeneratorResponse* msg, size_t* size) { + +// +UPB_INLINE const upb_Array* _google_protobuf_compiler_CodeGeneratorResponse_file_upb_array( + const google_protobuf_compiler_CodeGeneratorResponse* msg, size_t* size) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorResponse_msg_init(), 15); const upb_Array* arr = upb_Message_GetArray(UPB_UPCAST(msg), &field); if (size) { @@ -552,7 +608,9 @@ UPB_INLINE const upb_Array* _google_protobuf_compiler_CodeGeneratorResponse_file } return arr; } -UPB_INLINE upb_Array* _google_protobuf_compiler_CodeGeneratorResponse_file_mutable_upb_array(google_protobuf_compiler_CodeGeneratorResponse* msg, size_t* size, upb_Arena* arena) { + +UPB_INLINE upb_Array* _google_protobuf_compiler_CodeGeneratorResponse_file_mutable_upb_array( + google_protobuf_compiler_CodeGeneratorResponse* msg, size_t* size, upb_Arena* arena) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorResponse_msg_init(), 15); upb_Array* arr = upb_Message_GetOrCreateMutableArray(UPB_UPCAST(msg), &field, arena); @@ -562,23 +620,24 @@ UPB_INLINE upb_Array* _google_protobuf_compiler_CodeGeneratorResponse_file_mutab return arr; } -UPB_INLINE void google_protobuf_compiler_CodeGeneratorResponse_set_error(google_protobuf_compiler_CodeGeneratorResponse *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_compiler_CodeGeneratorResponse_set_error(google_protobuf_compiler_CodeGeneratorResponse* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorResponse_msg_init(), 1); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_compiler_CodeGeneratorResponse_set_supported_features(google_protobuf_compiler_CodeGeneratorResponse *msg, uint64_t value) { +UPB_INLINE void google_protobuf_compiler_CodeGeneratorResponse_set_supported_features(google_protobuf_compiler_CodeGeneratorResponse* msg, uint64_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorResponse_msg_init(), 2); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_compiler_CodeGeneratorResponse_set_minimum_edition(google_protobuf_compiler_CodeGeneratorResponse *msg, int32_t value) { +UPB_INLINE void google_protobuf_compiler_CodeGeneratorResponse_set_minimum_edition(google_protobuf_compiler_CodeGeneratorResponse* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorResponse_msg_init(), 3); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_compiler_CodeGeneratorResponse_set_maximum_edition(google_protobuf_compiler_CodeGeneratorResponse *msg, int32_t value) { +UPB_INLINE void google_protobuf_compiler_CodeGeneratorResponse_set_maximum_edition(google_protobuf_compiler_CodeGeneratorResponse* msg, int32_t value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorResponse_msg_init(), 4); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE google_protobuf_compiler_CodeGeneratorResponse_File** google_protobuf_compiler_CodeGeneratorResponse_mutable_file(google_protobuf_compiler_CodeGeneratorResponse* msg, size_t* size) { +UPB_INLINE google_protobuf_compiler_CodeGeneratorResponse_File** google_protobuf_compiler_CodeGeneratorResponse_mutable_file(google_protobuf_compiler_CodeGeneratorResponse* msg, + size_t* size) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorResponse_msg_init(), 15); upb_Array* arr = upb_Message_GetMutableArray(UPB_UPCAST(msg), &field); if (arr) { @@ -589,12 +648,16 @@ UPB_INLINE google_protobuf_compiler_CodeGeneratorResponse_File** google_protobuf return NULL; } } -UPB_INLINE google_protobuf_compiler_CodeGeneratorResponse_File** google_protobuf_compiler_CodeGeneratorResponse_resize_file(google_protobuf_compiler_CodeGeneratorResponse* msg, size_t size, upb_Arena* arena) { + +UPB_INLINE google_protobuf_compiler_CodeGeneratorResponse_File** google_protobuf_compiler_CodeGeneratorResponse_resize_file(google_protobuf_compiler_CodeGeneratorResponse* msg, + size_t size, + upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorResponse_msg_init(), 15); - return (google_protobuf_compiler_CodeGeneratorResponse_File**)upb_Message_ResizeArrayUninitialized(UPB_UPCAST(msg), - &field, size, arena); + return (google_protobuf_compiler_CodeGeneratorResponse_File**)upb_Message_ResizeArrayUninitialized( + UPB_UPCAST(msg), &field, size, arena); } -UPB_INLINE struct google_protobuf_compiler_CodeGeneratorResponse_File* google_protobuf_compiler_CodeGeneratorResponse_add_file(google_protobuf_compiler_CodeGeneratorResponse* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_compiler_CodeGeneratorResponse_File* google_protobuf_compiler_CodeGeneratorResponse_add_file( + google_protobuf_compiler_CodeGeneratorResponse* msg, upb_Arena* arena) { upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorResponse_msg_init(), 15); upb_Array* arr = upb_Message_GetOrCreateMutableArray( UPB_UPCAST(msg), &field, arena); @@ -602,7 +665,8 @@ UPB_INLINE struct google_protobuf_compiler_CodeGeneratorResponse_File* google_pr arr, arr->UPB_PRIVATE(size) + 1, arena)) { return NULL; } - struct google_protobuf_compiler_CodeGeneratorResponse_File* sub = (struct google_protobuf_compiler_CodeGeneratorResponse_File*)_upb_Message_New(google__protobuf__compiler__CodeGeneratorResponse__File_msg_init(), arena); + struct google_protobuf_compiler_CodeGeneratorResponse_File* sub = + (struct google_protobuf_compiler_CodeGeneratorResponse_File*)_upb_Message_New(google__protobuf__compiler__CodeGeneratorResponse__File_msg_init(), arena); if (!arr || !sub) return NULL; UPB_PRIVATE(_upb_Array_Set) (arr, arr->UPB_PRIVATE(size) - 1, &sub, sizeof(sub)); @@ -610,37 +674,39 @@ UPB_INLINE struct google_protobuf_compiler_CodeGeneratorResponse_File* google_pr } /* google.protobuf.compiler.CodeGeneratorResponse.File */ - UPB_INLINE google_protobuf_compiler_CodeGeneratorResponse_File* google_protobuf_compiler_CodeGeneratorResponse_File_new(upb_Arena* arena) { return (google_protobuf_compiler_CodeGeneratorResponse_File*)_upb_Message_New(google__protobuf__compiler__CodeGeneratorResponse__File_msg_init(), arena); } -UPB_INLINE google_protobuf_compiler_CodeGeneratorResponse_File* google_protobuf_compiler_CodeGeneratorResponse_File_parse(const char* buf, size_t size, upb_Arena* arena) { +UPB_INLINE google_protobuf_compiler_CodeGeneratorResponse_File* google_protobuf_compiler_CodeGeneratorResponse_File_parse(const char* buf, size_t size, + upb_Arena* arena) { google_protobuf_compiler_CodeGeneratorResponse_File* ret = google_protobuf_compiler_CodeGeneratorResponse_File_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__compiler__CodeGeneratorResponse__File_msg_init(), NULL, 0, arena) != - kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__compiler__CodeGeneratorResponse__File_msg_init(), NULL, 0, + arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE google_protobuf_compiler_CodeGeneratorResponse_File* google_protobuf_compiler_CodeGeneratorResponse_File_parse_ex(const char* buf, size_t size, - const upb_ExtensionRegistry* extreg, - int options, upb_Arena* arena) { +UPB_INLINE google_protobuf_compiler_CodeGeneratorResponse_File* google_protobuf_compiler_CodeGeneratorResponse_File_parse_ex( + const char* buf, size_t size, const upb_ExtensionRegistry* extreg, + int options, upb_Arena* arena) { google_protobuf_compiler_CodeGeneratorResponse_File* ret = google_protobuf_compiler_CodeGeneratorResponse_File_new(arena); if (!ret) return NULL; - if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__compiler__CodeGeneratorResponse__File_msg_init(), extreg, options, - arena) != kUpb_DecodeStatus_Ok) { + if (upb_Decode(buf, size, UPB_UPCAST(ret), google__protobuf__compiler__CodeGeneratorResponse__File_msg_init(), extreg, + options, arena) != kUpb_DecodeStatus_Ok) { return NULL; } return ret; } -UPB_INLINE char* google_protobuf_compiler_CodeGeneratorResponse_File_serialize(const google_protobuf_compiler_CodeGeneratorResponse_File* msg, upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_compiler_CodeGeneratorResponse_File_serialize(const google_protobuf_compiler_CodeGeneratorResponse_File* msg, + upb_Arena* arena, size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__compiler__CodeGeneratorResponse__File_msg_init(), 0, arena, &ptr, len); return ptr; } -UPB_INLINE char* google_protobuf_compiler_CodeGeneratorResponse_File_serialize_ex(const google_protobuf_compiler_CodeGeneratorResponse_File* msg, int options, - upb_Arena* arena, size_t* len) { +UPB_INLINE char* google_protobuf_compiler_CodeGeneratorResponse_File_serialize_ex(const google_protobuf_compiler_CodeGeneratorResponse_File* msg, + int options, upb_Arena* arena, + size_t* len) { char* ptr; (void)upb_Encode(UPB_UPCAST(msg), google__protobuf__compiler__CodeGeneratorResponse__File_msg_init(), options, arena, &ptr, len); return ptr; @@ -710,23 +776,24 @@ UPB_INLINE bool google_protobuf_compiler_CodeGeneratorResponse_File_has_generate return upb_Message_HasBaseField(UPB_UPCAST(msg), &field); } -UPB_INLINE void google_protobuf_compiler_CodeGeneratorResponse_File_set_name(google_protobuf_compiler_CodeGeneratorResponse_File *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_compiler_CodeGeneratorResponse_File_set_name(google_protobuf_compiler_CodeGeneratorResponse_File* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorResponse__File_msg_init(), 1); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_compiler_CodeGeneratorResponse_File_set_insertion_point(google_protobuf_compiler_CodeGeneratorResponse_File *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_compiler_CodeGeneratorResponse_File_set_insertion_point(google_protobuf_compiler_CodeGeneratorResponse_File* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorResponse__File_msg_init(), 2); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_compiler_CodeGeneratorResponse_File_set_content(google_protobuf_compiler_CodeGeneratorResponse_File *msg, upb_StringView value) { +UPB_INLINE void google_protobuf_compiler_CodeGeneratorResponse_File_set_content(google_protobuf_compiler_CodeGeneratorResponse_File* msg, upb_StringView value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorResponse__File_msg_init(), 15); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE void google_protobuf_compiler_CodeGeneratorResponse_File_set_generated_code_info(google_protobuf_compiler_CodeGeneratorResponse_File *msg, struct google_protobuf_GeneratedCodeInfo* value) { +UPB_INLINE void google_protobuf_compiler_CodeGeneratorResponse_File_set_generated_code_info(google_protobuf_compiler_CodeGeneratorResponse_File* msg, struct google_protobuf_GeneratedCodeInfo* value) { const upb_MiniTableField field = *upb_MiniTable_FindFieldByNumber(google__protobuf__compiler__CodeGeneratorResponse__File_msg_init(), 16); - upb_Message_SetBaseField((upb_Message *)msg, &field, &value); + upb_Message_SetBaseField((upb_Message*)msg, &field, &value); } -UPB_INLINE struct google_protobuf_GeneratedCodeInfo* google_protobuf_compiler_CodeGeneratorResponse_File_mutable_generated_code_info(google_protobuf_compiler_CodeGeneratorResponse_File* msg, upb_Arena* arena) { +UPB_INLINE struct google_protobuf_GeneratedCodeInfo* google_protobuf_compiler_CodeGeneratorResponse_File_mutable_generated_code_info( + google_protobuf_compiler_CodeGeneratorResponse_File* msg, upb_Arena* arena) { struct google_protobuf_GeneratedCodeInfo* sub = (struct google_protobuf_GeneratedCodeInfo*)google_protobuf_compiler_CodeGeneratorResponse_File_generated_code_info(msg); if (sub == NULL) { sub = (struct google_protobuf_GeneratedCodeInfo*)_upb_Message_New(google__protobuf__GeneratedCodeInfo_msg_init(), arena); @@ -736,9 +803,9 @@ UPB_INLINE struct google_protobuf_GeneratedCodeInfo* google_protobuf_compiler_Co } #ifdef __cplusplus -} /* extern "C" */ + } /* extern "C" */ #endif #include "upb/port/undef.inc" -#endif /* GOOGLE_PROTOBUF_COMPILER_PLUGIN_PROTO_UPB_H__UPB_H_ */ +#endif /* GOOGLE_PROTOBUF_COMPILER_PLUGIN_PROTO_UPB_H__UPB_H_ */