diff --git a/src/google/protobuf/compiler/cpp/field.cc b/src/google/protobuf/compiler/cpp/field.cc index 96a6bebdcf..8defa53e3d 100644 --- a/src/google/protobuf/compiler/cpp/field.cc +++ b/src/google/protobuf/compiler/cpp/field.cc @@ -65,17 +65,20 @@ absl::flat_hash_map FieldVars( const FieldDescriptor* field, const Options& opts) { bool split = ShouldSplit(field, opts); absl::flat_hash_map vars = { - {"ns", Namespace(field, opts)}, + // This will eventually be renamed to "field", once the existing "field" + // variable is replaced with "field_" everywhere. {"name", FieldName(field)}, + {"index", absl::StrCat(field->index())}, {"number", absl::StrCat(field->number())}, - {"classname", ClassName(FieldScope(field), false)}, - {"declared_type", DeclaredTypeMethodName(field->type())}, - {"field", FieldMemberName(field, split)}, - {"tag_size", + {"pkg.Msg.field", field->full_name()}, + + {"field_", FieldMemberName(field, split)}, + {"DeclaredType", DeclaredTypeMethodName(field->type())}, + {"kTagBytes", absl::StrCat(WireFormat::TagSize(field->number(), field->type()))}, {"deprecated_attr", DeprecatedAttribute(opts, field)}, - {"maybe_prepare_split_message", + {"PrepareSplitMessageForWrite", split ? "PrepareSplitMessageForWrite();" : ""}, // These variables are placeholders to pick out the beginning and ends of @@ -84,6 +87,16 @@ absl::flat_hash_map FieldVars( // but the empty string. {"{", ""}, {"}", ""}, + + // Old-style names. + {"field", FieldMemberName(field, split)}, + {"maybe_prepare_split_message", + split ? "PrepareSplitMessageForWrite();" : ""}, + {"declared_type", DeclaredTypeMethodName(field->type())}, + {"classname", ClassName(FieldScope(field), false)}, + {"ns", Namespace(field, opts)}, + {"tag_size", + absl::StrCat(WireFormat::TagSize(field->number(), field->type()))}, }; if (const auto* oneof = field->containing_oneof()) { @@ -192,7 +205,7 @@ std::unique_ptr MakeGenerator(const FieldDescriptor* field, case FieldDescriptor::CPPTYPE_ENUM: return MakeOneofEnumGenerator(field, options, scc); default: - return MakeOneofPrimitiveGenerator(field, options, scc); + return MakeSinguarPrimitiveGenerator(field, options, scc); } } @@ -225,12 +238,13 @@ void HasBitVars(const FieldDescriptor* field, const Options& opts, ? "_has_bits_" : "_impl_._has_bits_"; - vars.emplace_back("has_hasbit", - absl::StrFormat("%s[%d] & %s", has_bits, index, mask)); - vars.emplace_back("set_hasbit", - absl::StrFormat("%s[%d] |= %s;", has_bits, index, mask)); - vars.emplace_back("clear_hasbit", - absl::StrFormat("%s[%d] &= ~%s;", has_bits, index, mask)); + auto has = absl::StrFormat("%s[%d] & %s", has_bits, index, mask); + auto set = absl::StrFormat("%s[%d] |= %s;", has_bits, index, mask); + auto clr = absl::StrFormat("%s[%d] &= ~%s;", has_bits, index, mask); + + vars.emplace_back("has_hasbit", has); + vars.emplace_back(Sub("set_hasbit", set).WithSuffix(";")); + vars.emplace_back(Sub("clear_hasbit", clr).WithSuffix(";")); } void InlinedStringVars(const FieldDescriptor* field, const Options& opts, @@ -274,6 +288,11 @@ FieldGenerator::FieldGenerator(const FieldDescriptor* field, field_vars_.push_back(Sub{std::string(kv.first), kv.second}); } + // This is set up here rather than in FieldVars so we can set a prefix. + // The " " suffix allows us to write `$DEPRECATED$ int foo();` and such. + field_vars_.push_back( + Sub("DEPRECATED", DeprecatedAttribute(options, field)).WithSuffix(" ")); + HasBitVars(field, options, hasbit_index, field_vars_); InlinedStringVars(field, options, inlined_string_index, field_vars_); } diff --git a/src/google/protobuf/compiler/cpp/field.h b/src/google/protobuf/compiler/cpp/field.h index e30ab09af6..bf4fd444e4 100644 --- a/src/google/protobuf/compiler/cpp/field.h +++ b/src/google/protobuf/compiler/cpp/field.h @@ -291,6 +291,7 @@ class FieldGenerator { // The code that this method generates will be executed inside a // shared-for-the-whole-message-class method registered with OwnDestructor(). void GenerateArenaDestructorCode(io::Printer* p) const { + auto vars = PushVarsForCall(p); impl_->GenerateArenaDestructorCode(p); } diff --git a/src/google/protobuf/compiler/cpp/field_generators/generators.h b/src/google/protobuf/compiler/cpp/field_generators/generators.h index 6b9e53929b..a4961c7b87 100644 --- a/src/google/protobuf/compiler/cpp/field_generators/generators.h +++ b/src/google/protobuf/compiler/cpp/field_generators/generators.h @@ -59,10 +59,6 @@ std::unique_ptr MakeRepeatedPrimitiveGenerator( const FieldDescriptor* desc, const Options& options, MessageSCCAnalyzer* scc); -std::unique_ptr MakeOneofPrimitiveGenerator( - const FieldDescriptor* desc, const Options& options, - MessageSCCAnalyzer* scc); - std::unique_ptr MakeSinguarEnumGenerator( const FieldDescriptor* desc, const Options& options, MessageSCCAnalyzer* scc); diff --git a/src/google/protobuf/compiler/cpp/field_generators/primitive_field.cc b/src/google/protobuf/compiler/cpp/field_generators/primitive_field.cc index 686dee55f5..8624332902 100644 --- a/src/google/protobuf/compiler/cpp/field_generators/primitive_field.cc +++ b/src/google/protobuf/compiler/cpp/field_generators/primitive_field.cc @@ -41,6 +41,8 @@ #include "absl/container/flat_hash_map.h" #include "google/protobuf/stubs/logging.h" #include "absl/memory/memory.h" +#include "absl/strings/substitute.h" +#include "absl/types/optional.h" #include "google/protobuf/compiler/cpp/field_generators/generators.h" #include "google/protobuf/compiler/cpp/helpers.h" #include "google/protobuf/compiler/cpp/options.h" @@ -56,23 +58,24 @@ namespace { using ::google::protobuf::internal::WireFormat; using ::google::protobuf::internal::WireFormatLite; using Sub = ::google::protobuf::io::Printer::Sub; +using Annotation = ::google::protobuf::GeneratedCodeInfo::Annotation; -// For encodings with fixed sizes, returns that size in bytes. Otherwise -// returns -1. -int FixedSize(FieldDescriptor::Type type) { +// For encodings with fixed sizes, returns that size in bytes. +absl::optional FixedSize(FieldDescriptor::Type type) { switch (type) { case FieldDescriptor::TYPE_INT32: - return -1; case FieldDescriptor::TYPE_INT64: - return -1; case FieldDescriptor::TYPE_UINT32: - return -1; case FieldDescriptor::TYPE_UINT64: - return -1; case FieldDescriptor::TYPE_SINT32: - return -1; case FieldDescriptor::TYPE_SINT64: - return -1; + case FieldDescriptor::TYPE_ENUM: + case FieldDescriptor::TYPE_STRING: + case FieldDescriptor::TYPE_BYTES: + case FieldDescriptor::TYPE_GROUP: + case FieldDescriptor::TYPE_MESSAGE: + return absl::nullopt; + case FieldDescriptor::TYPE_FIXED32: return WireFormatLite::kFixed32Size; case FieldDescriptor::TYPE_FIXED64: @@ -85,524 +88,494 @@ int FixedSize(FieldDescriptor::Type type) { return WireFormatLite::kFloatSize; case FieldDescriptor::TYPE_DOUBLE: return WireFormatLite::kDoubleSize; - case FieldDescriptor::TYPE_BOOL: return WireFormatLite::kBoolSize; - case FieldDescriptor::TYPE_ENUM: - return -1; - - case FieldDescriptor::TYPE_STRING: - return -1; - case FieldDescriptor::TYPE_BYTES: - return -1; - case FieldDescriptor::TYPE_GROUP: - return -1; - case FieldDescriptor::TYPE_MESSAGE: - return -1; // No default because we want the compiler to complain if any new // types are added. } + GOOGLE_ABSL_LOG(FATAL) << "Can't get here."; - return -1; + return absl::nullopt; } std::vector Vars(const FieldDescriptor* field, const Options& options) { bool cold = ShouldSplit(field, options); return { - {"type", PrimitiveTypeName(options, field->cpp_type())}, - {"default", DefaultValue(options, field)}, - {"cached_byte_size_name", MakeVarintCachedSizeName(field)}, - {"cached_byte_size_field", MakeVarintCachedSizeFieldName(field, cold)}, - {"tag", WireFormat::MakeTag(field)}, - {"fixed_size", FixedSize(field->type())}, - {"wire_format_field_type", - FieldDescriptorProto_Type_Name( - static_cast(field->type()))}, - {"full_name", field->full_name()}, + {"Type", PrimitiveTypeName(options, field->cpp_type())}, + {"kDefault", DefaultValue(options, field)}, + {"_field_cached_byte_size_", MakeVarintCachedSizeFieldName(field, cold)}, }; } -class PrimitiveFieldGenerator : public FieldGeneratorBase { +class SingularPrimitive final : public FieldGeneratorBase { public: - PrimitiveFieldGenerator(const FieldDescriptor* descriptor, - const Options& options); - ~PrimitiveFieldGenerator() override = default; - - std::vector MakeVars() const override { - return Vars(descriptor_, options_); + SingularPrimitive(const FieldDescriptor* field, const Options& opts) + : FieldGeneratorBase(field, opts), + field_(field), + opts_(&opts), + is_oneof_(field_->real_containing_oneof() != nullptr) {} + ~SingularPrimitive() override = default; + + std::vector MakeVars() const override { return Vars(field_, *opts_); } + + void GeneratePrivateMembers(io::Printer* p) const override { + p->Emit(R"cc( + $Type$ $name$_; + )cc"); } - void GeneratePrivateMembers(io::Printer* printer) const override; - void GenerateAccessorDeclarations(io::Printer* printer) const override; - void GenerateInlineAccessorDefinitions(io::Printer* printer) const override; - void GenerateClearingCode(io::Printer* printer) const override; - void GenerateMergingCode(io::Printer* printer) const override; - void GenerateSwappingCode(io::Printer* printer) const override; - void GenerateConstructorCode(io::Printer* printer) const override {} - void GenerateCopyConstructorCode(io::Printer* printer) const override; - void GenerateSerializeWithCachedSizesToArray( - io::Printer* printer) const override; - void GenerateByteSize(io::Printer* printer) const override; - void GenerateConstexprAggregateInitializer( - io::Printer* printer) const override; - void GenerateAggregateInitializer(io::Printer* printer) const override; - void GenerateCopyAggregateInitializer(io::Printer* printer) const override; -}; - -class PrimitiveOneofFieldGenerator : public PrimitiveFieldGenerator { - public: - PrimitiveOneofFieldGenerator(const FieldDescriptor* descriptor, - const Options& options); - ~PrimitiveOneofFieldGenerator() override = default; - - void GenerateInlineAccessorDefinitions(io::Printer* printer) const override; - void GenerateClearingCode(io::Printer* printer) const override; - void GenerateSwappingCode(io::Printer* printer) const override; - void GenerateConstructorCode(io::Printer* printer) const override; -}; - -class RepeatedPrimitiveFieldGenerator : public FieldGeneratorBase { - public: - RepeatedPrimitiveFieldGenerator(const FieldDescriptor* descriptor, - const Options& options); - ~RepeatedPrimitiveFieldGenerator() override = default; - - std::vector MakeVars() const override { - return Vars(descriptor_, options_); + void GenerateClearingCode(io::Printer* p) const override { + p->Emit(R"cc( + $field_$ = $kDefault$; + )cc"); } - void GeneratePrivateMembers(io::Printer* printer) const override; - void GenerateAccessorDeclarations(io::Printer* printer) const override; - void GenerateInlineAccessorDefinitions(io::Printer* printer) const override; - void GenerateClearingCode(io::Printer* printer) const override; - void GenerateMergingCode(io::Printer* printer) const override; - void GenerateSwappingCode(io::Printer* printer) const override; - void GenerateConstructorCode(io::Printer* printer) const override {} - void GenerateCopyConstructorCode(io::Printer* /*printer*/) const override { - GOOGLE_ABSL_CHECK(!ShouldSplit(descriptor_, options_)); + void GenerateMergingCode(io::Printer* p) const override { + p->Emit(R"cc( + _this->_internal_set_$name$(from._internal_$name$()); + )cc"); } - void GenerateDestructorCode(io::Printer* printer) const override; - void GenerateSerializeWithCachedSizesToArray( - io::Printer* printer) const override; - void GenerateByteSize(io::Printer* printer) const override; - void GenerateConstexprAggregateInitializer( - io::Printer* printer) const override; - void GenerateAggregateInitializer(io::Printer* printer) const override; - void GenerateCopyAggregateInitializer(io::Printer* printer) const override; -}; -PrimitiveFieldGenerator::PrimitiveFieldGenerator( - const FieldDescriptor* descriptor, const Options& options) - : FieldGeneratorBase(descriptor, options) {} + void GenerateSwappingCode(io::Printer* p) const override { + if (is_oneof_) { + // Don't print any swapping code. Swapping the union will swap this field. + return; + } -void PrimitiveFieldGenerator::GeneratePrivateMembers( - io::Printer* printer) const { - Formatter format(printer); - format("$type$ $name$_;\n"); -} + p->Emit(R"cc( + //~ A `using std::swap;` is already present in this function. + swap($field_$, other->$field_$); + )cc"); + } -void PrimitiveFieldGenerator::GenerateAccessorDeclarations( - io::Printer* printer) const { - Formatter format(printer); - format("$deprecated_attr$$type$ ${1$$name$$}$() const;\n", descriptor_); - format("$deprecated_attr$void ${1$set_$name$$}$($type$ value);\n", - std::make_tuple(descriptor_, GeneratedCodeInfo::Annotation::SET)); - format( - "private:\n" - "$type$ ${1$_internal_$name$$}$() const;\n" - "void ${1$_internal_set_$name$$}$($type$ value);\n" - "public:\n", - descriptor_); -} + void GenerateConstructorCode(io::Printer* p) const override { + if (!is_oneof_) { + return; + } -void PrimitiveFieldGenerator::GenerateInlineAccessorDefinitions( - io::Printer* printer) const { - Formatter format(printer); - format( - "inline $type$ $classname$::_internal_$name$() const {\n" - " return $field$;\n" - "}\n" - "inline $type$ $classname$::$name$() const {\n" - "$annotate_get$" - " // @@protoc_insertion_point(field_get:$full_name$)\n" - " return _internal_$name$();\n" - "}\n" - "inline void $classname$::_internal_set_$name$($type$ value) {\n" - " $set_hasbit$\n" - " $field$ = value;\n" - "}\n" - "inline void $classname$::set_$name$($type$ value) {\n" - "$maybe_prepare_split_message$" - " _internal_set_$name$(value);\n" - "$annotate_set$" - " // @@protoc_insertion_point(field_set:$full_name$)\n" - "}\n"); -} + p->Emit(R"cc( + $pkg$::_$Msg$_default_instance_.$field_$ = $kDefault$; + )cc"); + } -void PrimitiveFieldGenerator::GenerateClearingCode(io::Printer* printer) const { - Formatter format(printer); - format("$field$ = $default$;\n"); -} + void GenerateCopyConstructorCode(io::Printer* p) const override { + p->Emit(R"cc( + _this->$field_$ = from.$field_$; + )cc"); + } -void PrimitiveFieldGenerator::GenerateMergingCode(io::Printer* printer) const { - Formatter format(printer); - format("_this->_internal_set_$name$(from._internal_$name$());\n"); -} + void GenerateConstexprAggregateInitializer(io::Printer* p) const override { + p->Emit(R"cc( + /* .$field_$ = */ $kDefault$ + )cc"); + } -void PrimitiveFieldGenerator::GenerateSwappingCode(io::Printer* printer) const { - Formatter format(printer); - format("swap($field$, other->$field$);\n"); -} + void GenerateAggregateInitializer(io::Printer* p) const override { + p->Emit(R"cc( + decltype($field_$) { $kDefault$ } + )cc"); + } -void PrimitiveFieldGenerator::GenerateCopyConstructorCode( - io::Printer* printer) const { - Formatter format(printer); - format("_this->$field$ = from.$field$;\n"); -} + void GenerateCopyAggregateInitializer(io::Printer* p) const override { + p->Emit(R"cc( + decltype($field_$) {} + )cc"); + } -void PrimitiveFieldGenerator::GenerateSerializeWithCachedSizesToArray( - io::Printer* printer) const { - Formatter format(printer); - format( - "target = stream->EnsureSpace(target);\n" - "target = " - "::_pbi::WireFormatLite::Write$declared_type$ToArray(" - "$number$, this->_internal_$name$(), target);\n"); -} + void GenerateAccessorDeclarations(io::Printer* p) const override; + void GenerateInlineAccessorDefinitions(io::Printer* p) const override; + void GenerateSerializeWithCachedSizesToArray(io::Printer* p) const override; + void GenerateByteSize(io::Printer* p) const override; + + private: + const FieldDescriptor* field_; + const Options* opts_; + bool is_oneof_; +}; -void PrimitiveFieldGenerator::GenerateByteSize(io::Printer* printer) const { - Formatter format(printer); - int fixed_size = FixedSize(descriptor_->type()); - if (fixed_size == -1) { - if (internal::WireFormat::TagSize(descriptor_->number(), - descriptor_->type()) == 1) { - // Adding one is very common and it turns out it can be done for - // free inside of WireFormatLite, so we can save an instruction here. - format( - "total_size += ::_pbi::WireFormatLite::" - "$declared_type$SizePlusOne(this->_internal_$name$());\n"); - } else { - format( - "total_size += $tag_size$ +\n" - " ::_pbi::WireFormatLite::$declared_type$Size(\n" - " this->_internal_$name$());\n"); +void SingularPrimitive::GenerateAccessorDeclarations(io::Printer* p) const { + p->Emit( + { + Sub("name", p->LookupVar("name")).AnnotatedAs(field_), + Sub("set_name", absl::StrCat("set_", p->LookupVar("name"))) + .AnnotatedAs(field_), + Sub("_internal_name", + absl::StrCat("_internal_", p->LookupVar("name"))) + .AnnotatedAs(field_), + Sub("_internal_set_name", + absl::StrCat("_internal_set_", p->LookupVar("name"))) + .AnnotatedAs(field_), + }, + R"cc( + $DEPRECATED$ $Type$ $name$() const; + $DEPRECATED$ void $set_name$($Type$ value); + + private: + $Type$ $_internal_name$() const; + void $_internal_set_name$($Type$ value); + + public: + )cc"); +} + +void SingularPrimitive::GenerateInlineAccessorDefinitions( + io::Printer* p) const { + p->Emit(R"cc( + inline $Type$ $Msg$::$name$() const { + $annotate_get$; + // @@protoc_insertion_point(field_get:$pkg.Msg.field$) + return _internal_$name$(); } + inline void $Msg$::set_$name$($Type$ value) { + $PrepareSplitMessageForWrite$; + _internal_set_$name$(value); + $annotate_set$; + // @@protoc_insertion_point(field_set:$pkg.Msg.field$) + } + )cc"); + + if (is_oneof_) { + p->Emit(R"cc( + inline $Type$ $Msg$::_internal_$name$() const { + if ($has_field$) { + return $field_$; + } + return $kDefault$; + } + inline void $Msg$::_internal_set_$name$($Type$ value) { + if ($not_has_field$) { + clear_$oneof_name$(); + set_has_$name$(); + } + $field_$ = value; + } + )cc"); } else { - format("total_size += $tag_size$ + $fixed_size$;\n"); + p->Emit(R"cc( + inline $Type$ $Msg$::_internal_$name$() const { + return $field_$; + } + inline void $Msg$::_internal_set_$name$($Type$ value) { + $set_hasbit$; + $field_$ = value; + } + )cc"); } } -void PrimitiveFieldGenerator::GenerateConstexprAggregateInitializer( - io::Printer* printer) const { - Formatter format(printer); - format("/*decltype($field$)*/$default$"); +void SingularPrimitive::GenerateSerializeWithCachedSizesToArray( + io::Printer* p) const { + p->Emit(R"cc( + target = stream->EnsureSpace(target); + target = ::_pbi::WireFormatLite::Write$DeclaredType$ToArray( + $number$, this->_internal_$name$(), target); + )cc"); } -void PrimitiveFieldGenerator::GenerateAggregateInitializer( - io::Printer* printer) const { - Formatter format(printer); - if (ShouldSplit(descriptor_, options_)) { - format("decltype(Impl_::Split::$name$_){$default$}"); +void SingularPrimitive::GenerateByteSize(io::Printer* p) const { + size_t tag_size = WireFormat::TagSize(field_->number(), field_->type()); + + auto fixed_size = FixedSize(field_->type()); + if (fixed_size.has_value()) { + p->Emit({{"kFixedBytes", tag_size + *fixed_size}}, R"cc( + total_size += $kFixedBytes$; + )cc"); return; } - format("decltype($field$){$default$}"); -} -void PrimitiveFieldGenerator::GenerateCopyAggregateInitializer( - io::Printer* printer) const { - Formatter format(printer); - format("decltype($field$){}"); -} - -// =================================================================== - -PrimitiveOneofFieldGenerator::PrimitiveOneofFieldGenerator( - const FieldDescriptor* descriptor, const Options& options) - : PrimitiveFieldGenerator(descriptor, options) { - SetCommonOneofFieldVariables(descriptor, &variables_); -} - -void PrimitiveOneofFieldGenerator::GenerateInlineAccessorDefinitions( - io::Printer* printer) const { - Formatter format(printer); - format( - "inline $type$ $classname$::_internal_$name$() const {\n" - " if ($has_field$) {\n" - " return $field$;\n" - " }\n" - " return $default$;\n" - "}\n" - "inline void $classname$::_internal_set_$name$($type$ value) {\n" - " if ($not_has_field$) {\n" - " clear_$oneof_name$();\n" - " set_has_$name$();\n" - " }\n" - " $field$ = value;\n" - "}\n" - "inline $type$ $classname$::$name$() const {\n" - "$annotate_get$" - " // @@protoc_insertion_point(field_get:$full_name$)\n" - " return _internal_$name$();\n" - "}\n" - "inline void $classname$::set_$name$($type$ value) {\n" - " _internal_set_$name$(value);\n" - "$annotate_set$" - " // @@protoc_insertion_point(field_set:$full_name$)\n" - "}\n"); -} + // Adding one is very common and it turns out it can be done for + // free inside of WireFormatLite, so we can save an instruction here. + if (tag_size == 1) { + p->Emit(R"cc( + total_size += ::_pbi::WireFormatLite::$DeclaredType$SizePlusOne( + this->_internal_$name$()); + )cc"); + return; + } -void PrimitiveOneofFieldGenerator::GenerateClearingCode( - io::Printer* printer) const { - Formatter format(printer); - format("$field$ = $default$;\n"); + p->Emit(R"cc( + total_size += $kTagBytes$ + ::_pbi::WireFormatLite::$DeclaredType$Size( + this->_internal_$name$()); + )cc"); } -void PrimitiveOneofFieldGenerator::GenerateSwappingCode( - io::Printer* printer) const { - // Don't print any swapping code. Swapping the union will swap this field. -} +class RepeatedPrimitive final : public FieldGeneratorBase { + public: + RepeatedPrimitive(const FieldDescriptor* field, const Options& opts) + : FieldGeneratorBase(field, opts), field_(field), opts_(&opts) {} + ~RepeatedPrimitive() override = default; -void PrimitiveOneofFieldGenerator::GenerateConstructorCode( - io::Printer* printer) const { - Formatter format(printer); - format("$ns$::_$classname$_default_instance_.$field$ = $default$;\n"); -} + std::vector MakeVars() const override { return Vars(field_, *opts_); } -// =================================================================== - -RepeatedPrimitiveFieldGenerator::RepeatedPrimitiveFieldGenerator( - const FieldDescriptor* descriptor, const Options& options) - : FieldGeneratorBase(descriptor, options) {} - -void RepeatedPrimitiveFieldGenerator::GeneratePrivateMembers( - io::Printer* printer) const { - Formatter format(printer); - format("::$proto_ns$::RepeatedField< $type$ > $name$_;\n"); - if (descriptor_->is_packed() && FixedSize(descriptor_->type()) == -1 && - HasGeneratedMethods(descriptor_->file(), options_)) { - format( - "mutable ::$proto_ns$::internal::CachedSize " - "$cached_byte_size_name$;\n"); + void GenerateClearingCode(io::Printer* p) const override { + p->Emit(R"cc( + $field_$.Clear(); + )cc"); } -} -void RepeatedPrimitiveFieldGenerator::GenerateAccessorDeclarations( - io::Printer* printer) const { - Formatter format(printer); - format( - "private:\n" - "$type$ ${1$_internal_$name$$}$(int index) const;\n" - "const ::$proto_ns$::RepeatedField< $type$ >&\n" - " ${1$_internal_$name$$}$() const;\n" - "void ${1$_internal_add_$name$$}$($type$ value);\n" - "::$proto_ns$::RepeatedField< $type$ >*\n" - " ${1$_internal_mutable_$name$$}$();\n" - "public:\n" - "$deprecated_attr$$type$ ${1$$name$$}$(int index) const;\n" - "$deprecated_attr$void ${1$set_$name$$}$(int index, $type$ value);\n" - "$deprecated_attr$void ${1$add_$name$$}$($type$ value);\n" - "$deprecated_attr$const ::$proto_ns$::RepeatedField< $type$ >&\n" - " ${1$$name$$}$() const;\n" - "$deprecated_attr$::$proto_ns$::RepeatedField< $type$ >*\n" - " ${1$mutable_$name$$}$();\n", - descriptor_); -} - -void RepeatedPrimitiveFieldGenerator::GenerateInlineAccessorDefinitions( - io::Printer* printer) const { - Formatter format(printer); - format( - "inline $type$ $classname$::_internal_$name$(int index) const {\n" - " return $field$.Get(index);\n" - "}\n" - "inline $type$ $classname$::$name$(int index) const {\n" - "$annotate_get$" - " // @@protoc_insertion_point(field_get:$full_name$)\n" - " return _internal_$name$(index);\n" - "}\n" - "inline void $classname$::set_$name$(int index, $type$ value) {\n" - "$annotate_set$" - " $field$.Set(index, value);\n" - " // @@protoc_insertion_point(field_set:$full_name$)\n" - "}\n" - "inline void $classname$::_internal_add_$name$($type$ value) {\n" - " $field$.Add(value);\n" - "}\n" - "inline void $classname$::add_$name$($type$ value) {\n" - " _internal_add_$name$(value);\n" - "$annotate_add$" - " // @@protoc_insertion_point(field_add:$full_name$)\n" - "}\n" - "inline const ::$proto_ns$::RepeatedField< $type$ >&\n" - "$classname$::_internal_$name$() const {\n" - " return $field$;\n" - "}\n" - "inline const ::$proto_ns$::RepeatedField< $type$ >&\n" - "$classname$::$name$() const {\n" - "$annotate_list$" - " // @@protoc_insertion_point(field_list:$full_name$)\n" - " return _internal_$name$();\n" - "}\n" - "inline ::$proto_ns$::RepeatedField< $type$ >*\n" - "$classname$::_internal_mutable_$name$() {\n" - " return &$field$;\n" - "}\n" - "inline ::$proto_ns$::RepeatedField< $type$ >*\n" - "$classname$::mutable_$name$() {\n" - "$annotate_mutable_list$" - " // @@protoc_insertion_point(field_mutable_list:$full_name$)\n" - " return _internal_mutable_$name$();\n" - "}\n"); -} + void GenerateMergingCode(io::Printer* p) const override { + p->Emit(R"cc( + _this->$field_$.MergeFrom(from.$field_$); + )cc"); + } -void RepeatedPrimitiveFieldGenerator::GenerateClearingCode( - io::Printer* printer) const { - Formatter format(printer); - format("$field$.Clear();\n"); -} + void GenerateSwappingCode(io::Printer* p) const override { + p->Emit(R"cc( + $field_$.InternalSwap(&other->$field_$); + )cc"); + } -void RepeatedPrimitiveFieldGenerator::GenerateMergingCode( - io::Printer* printer) const { - Formatter format(printer); - format("_this->$field$.MergeFrom(from.$field$);\n"); -} + void GenerateDestructorCode(io::Printer* p) const override { + p->Emit(R"cc( + $field_$.~RepeatedField(); + )cc"); + } -void RepeatedPrimitiveFieldGenerator::GenerateSwappingCode( - io::Printer* printer) const { - Formatter format(printer); - format("$field$.InternalSwap(&other->$field$);\n"); -} + void GenerateConstructorCode(io::Printer* p) const override {} -void RepeatedPrimitiveFieldGenerator::GenerateDestructorCode( - io::Printer* printer) const { - Formatter format(printer); - format("$field$.~RepeatedField();\n"); -} + void GenerateCopyConstructorCode(io::Printer* p) const override { + GOOGLE_ABSL_CHECK(!ShouldSplit(field_, *opts_)); + } -void RepeatedPrimitiveFieldGenerator::GenerateSerializeWithCachedSizesToArray( - io::Printer* printer) const { - Formatter format(printer); - if (descriptor_->is_packed()) { - if (FixedSize(descriptor_->type()) == -1) { - format( - "{\n" - " int byte_size = " - "$cached_byte_size_field$.Get();\n" - " if (byte_size > 0) {\n" - " target = stream->Write$declared_type$Packed(\n" - " $number$, _internal_$name$(), byte_size, target);\n" - " }\n" - "}\n"); - } else { - format( - "if (this->_internal_$name$_size() > 0) {\n" - " target = stream->WriteFixedPacked($number$, _internal_$name$(), " - "target);\n" - "}\n"); - } - } else { - format( - "for (int i = 0, n = this->_internal_$name$_size(); i < n; i++) {\n" - " target = stream->EnsureSpace(target);\n" - " target = ::_pbi::WireFormatLite::" - "Write$declared_type$ToArray($number$, this->_internal_$name$(i), " - "target);\n" - "}\n"); + void GenerateConstexprAggregateInitializer(io::Printer* p) const override { + p->Emit(R"cc( + /* .$field_$ = */ {} + )cc"); + InitCachedSize(p); } -} -void RepeatedPrimitiveFieldGenerator::GenerateByteSize( - io::Printer* printer) const { - Formatter format(printer); - format("{\n"); - format.Indent(); - int fixed_size = FixedSize(descriptor_->type()); - if (fixed_size == -1) { - format( - "::size_t data_size = ::_pbi::WireFormatLite::\n" - " $declared_type$Size(this->$field$);\n"); - } else { - format( - "unsigned int count = static_cast(this->_internal_$name$_size());\n" - "::size_t data_size = $fixed_size$UL * count;\n"); + void GenerateAggregateInitializer(io::Printer* p) const override { + p->Emit(R"cc( + decltype($field_$) { arena } + )cc"); + InitCachedSize(p); } - if (descriptor_->is_packed()) { - format( - "if (data_size > 0) {\n" - " total_size += $tag_size$ +\n" - " " - "::_pbi::WireFormatLite::Int32Size(static_cast<$int32$>(data_size));\n" - "}\n"); - if (FixedSize(descriptor_->type()) == -1) { - format( - "int cached_size = ::_pbi::ToCachedSize(data_size);\n" - "$cached_byte_size_field$.Set(cached_size);\n"); - } - format("total_size += data_size;\n"); - } else { - format( - "total_size += $tag_size$ *\n" - " " - "::_pbi::FromIntSize(this->_internal_$name$_size());\n" - "total_size += data_size;\n"); + void GenerateCopyAggregateInitializer(io::Printer* p) const override { + p->Emit(R"cc( + decltype($field_$) { from.$field_$ } + )cc"); + InitCachedSize(p); } - format.Outdent(); - format("}\n"); -} -void RepeatedPrimitiveFieldGenerator::GenerateConstexprAggregateInitializer( - io::Printer* printer) const { - Formatter format(printer); - format("/*decltype($field$)*/{}"); - if (descriptor_->is_packed() && FixedSize(descriptor_->type()) == -1 && - HasGeneratedMethods(descriptor_->file(), options_)) { - format("\n, /*decltype($cached_byte_size_field$)*/{0}"); + void GeneratePrivateMembers(io::Printer* p) const override; + void GenerateAccessorDeclarations(io::Printer* p) const override; + void GenerateInlineAccessorDefinitions(io::Printer* p) const override; + void GenerateSerializeWithCachedSizesToArray(io::Printer* p) const override; + void GenerateByteSize(io::Printer* p) const override; + + private: + bool HasCachedSize() const { + bool is_packed_varint = + field_->is_packed() && !FixedSize(field_->type()).has_value(); + return is_packed_varint && HasGeneratedMethods(field_->file(), *opts_); } -} -void RepeatedPrimitiveFieldGenerator::GenerateAggregateInitializer( - io::Printer* printer) const { - Formatter format(printer); - format("decltype($field$){arena}"); - if (descriptor_->is_packed() && FixedSize(descriptor_->type()) == -1 && - HasGeneratedMethods(descriptor_->file(), options_)) { + void InitCachedSize(io::Printer* p) const { + if (!HasCachedSize()) return; // std::atomic has no move constructor, which prevents explicit aggregate // initialization pre-C++17. - format("\n, /*decltype($cached_byte_size_field$)*/{0}"); + p->Emit(R"( + ,/* $_field_cached_byte_size_$ = */ { 0 } + )"); + } + + const FieldDescriptor* field_; + const Options* opts_; +}; + +void RepeatedPrimitive::GeneratePrivateMembers(io::Printer* p) const { + p->Emit(R"cc( + $pb$::RepeatedField<$Type$> $name$_; + )cc"); + + if (HasCachedSize()) { + p->Emit({{"_cached_size_", MakeVarintCachedSizeName(field_)}}, + R"cc( + mutable $pbi$::CachedSize $_cached_size_$; + )cc"); } } -void RepeatedPrimitiveFieldGenerator::GenerateCopyAggregateInitializer( - io::Printer* printer) const { - Formatter format(printer); - format("decltype($field$){from.$field$}"); - if (descriptor_->is_packed() && FixedSize(descriptor_->type()) == -1 && - HasGeneratedMethods(descriptor_->file(), options_)) { - // std::atomic has no move constructor. - format("\n, /*decltype($cached_byte_size_field$)*/{0}"); +void RepeatedPrimitive::GenerateAccessorDeclarations(io::Printer* p) const { + p->Emit( + { + Sub("name", p->LookupVar("name")).AnnotatedAs(field_), + Sub("set_name", absl::StrCat("set_", p->LookupVar("name"))) + .AnnotatedAs(field_), + Sub("add_name", absl::StrCat("add_", p->LookupVar("name"))) + .AnnotatedAs(field_), + Sub("mutable_name", absl::StrCat("mutable_", p->LookupVar("name"))) + .AnnotatedAs(field_), + + Sub("_internal_name", + absl::StrCat("_internal_", p->LookupVar("name"))) + .AnnotatedAs(field_), + Sub("_internal_add_name", + absl::StrCat("_internal_add_", p->LookupVar("name"))) + .AnnotatedAs(field_), + Sub("_internal_mutable_name", + absl::StrCat("_internal_mutable_", p->LookupVar("name"))) + .AnnotatedAs(field_), + }, + R"cc( + $DEPRECATED$ $Type$ $name$(int index) const; + $DEPRECATED$ void $set_name$(int index, $Type$ value); + $DEPRECATED$ void $add_name$($Type$ value); + $DEPRECATED$ const $pb$::RepeatedField<$Type$>& $name$() const; + $DEPRECATED$ $pb$::RepeatedField<$Type$>* $mutable_name$(); + + private: + $Type$ $_internal_name$(int index) const; + void $_internal_add_name$($Type$ value); + const $pb$::RepeatedField<$Type$>& $_internal_name$() const; + $pb$::RepeatedField<$Type$>* $_internal_mutable_name$(); + + public: + )cc"); +} + +void RepeatedPrimitive::GenerateInlineAccessorDefinitions( + io::Printer* p) const { + p->Emit(R"cc( + inline $Type$ $Msg$::$name$(int index) const { + $annotate_get$; + // @@protoc_insertion_point(field_get:$pkg.Msg.field$) + return _internal_$name$(index); + } + inline void $Msg$::set_$name$(int index, $Type$ value) { + $annotate_set$; + $field_$.Set(index, value); + // @@protoc_insertion_point(field_set:$pkg.Msg.field$) + } + inline void $Msg$::add_$name$($Type$ value) { + _internal_add_$name$(value); + $annotate_add$; + // @@protoc_insertion_point(field_add:$pkg.Msg.field$) + } + inline const $pb$::RepeatedField<$Type$>& $Msg$::$name$() const { + $annotate_list$; + // @@protoc_insertion_point(field_list:$pkg.Msg.field$) + return _internal_$name$(); + } + inline $pb$::RepeatedField<$Type$>* $Msg$::mutable_$name$() { + $annotate_mutable_list$; + // @@protoc_insertion_point(field_mutable_list:$pkg.Msg.field$) + return _internal_mutable_$name$(); + } + + inline $Type$ $Msg$::_internal_$name$(int index) const { + return $field_$.Get(index); + } + inline void $Msg$::_internal_add_$name$($Type$ value) { $field_$.Add(value); } + inline const $pb$::RepeatedField<$Type$>& $Msg$::_internal_$name$() const { + return $field_$; + } + inline $pb$::RepeatedField<$Type$>* $Msg$::_internal_mutable_$name$() { + return &$field_$; + } + )cc"); +} + +void RepeatedPrimitive::GenerateSerializeWithCachedSizesToArray( + io::Printer* p) const { + if (!field_->is_packed()) { + p->Emit(R"cc( + for (int i = 0, n = this->_internal_$name$_size(); i < n; ++i) { + target = stream->EnsureSpace(target); + target = ::_pbi::WireFormatLite::Write$DeclaredType$ToArray( + $number$, this->_internal_$name$(i), target); + } + )cc"); + return; + } + + if (FixedSize(field_->type()).has_value()) { + p->Emit(R"cc( + if (this->_internal_$name$_size() > 0) { + target = stream->WriteFixedPacked($number$, _internal_$name$(), target); + } + )cc"); + return; } + + p->Emit(R"cc( + { + int byte_size = $_field_cached_byte_size_$.Get(); + if (byte_size > 0) { + target = stream->Write$DeclaredType$Packed($number$, _internal_$name$(), + byte_size, target); + } + } + )cc"); +} + +void RepeatedPrimitive::GenerateByteSize(io::Printer* p) const { + p->Emit( + { + Sub{"data_size", + [&] { + auto fixed_size = FixedSize(descriptor_->type()); + if (fixed_size.has_value()) { + p->Emit({{"kFixed", *fixed_size}}, R"cc( + std::size_t{$kFixed$} * + ::_pbi::FromIntSize(this->_internal_$name$_size()) + )cc"); + } else { + p->Emit(R"cc( + ::_pbi::WireFormatLite::$DeclaredType$Size(this->$field_$) + )cc"); + } + }} // Here and below, we need to disable the default ;-chomping + // that closure substitutions do. + .WithSuffix(""), + {"maybe_cache_data_size", + [&] { + if (!HasCachedSize()) return; + p->Emit(R"cc( + $_field_cached_byte_size_$.Set(::_pbi::ToCachedSize(data_size)); + )cc"); + }}, + Sub{"tag_size", + [&] { + if (field_->is_packed()) { + p->Emit(R"cc( + data_size == 0 + ? 0 + : $kTagBytes$ + ::_pbi::WireFormatLite::Int32Size( + static_cast(data_size)) + )cc"); + } else { + p->Emit(R"cc( + std::size_t{$kTagBytes$} * + ::_pbi::FromIntSize(this->_internal_$name$_size()); + )cc"); + } + }} + .WithSuffix(""), + }, + R"cc( + { + std::size_t data_size = $data_size$; + $maybe_cache_data_size$; + std::size_t tag_size = $tag_size$; + total_size += tag_size + data_size; + } + )cc"); } } // namespace std::unique_ptr MakeSinguarPrimitiveGenerator( const FieldDescriptor* desc, const Options& options, MessageSCCAnalyzer* scc) { - return absl::make_unique(desc, options); + return absl::make_unique(desc, options); } std::unique_ptr MakeRepeatedPrimitiveGenerator( const FieldDescriptor* desc, const Options& options, MessageSCCAnalyzer* scc) { - return absl::make_unique(desc, options); -} - -std::unique_ptr MakeOneofPrimitiveGenerator( - const FieldDescriptor* desc, const Options& options, - MessageSCCAnalyzer* scc) { - return absl::make_unique(desc, options); + return absl::make_unique(desc, options); } } // namespace cpp diff --git a/src/google/protobuf/compiler/cpp/message.cc b/src/google/protobuf/compiler/cpp/message.cc index e8d734482d..8b472fd748 100644 --- a/src/google/protobuf/compiler/cpp/message.cc +++ b/src/google/protobuf/compiler/cpp/message.cc @@ -498,6 +498,7 @@ absl::flat_hash_map ClassVars( const Descriptor* desc, Options opts) { absl::flat_hash_map vars = MessageVars(desc); + vars.emplace("pkg", Namespace(desc, opts)); vars.emplace("Msg", ClassName(desc, false)); vars.emplace("pkg::Msg", QualifiedClassName(desc, opts)); vars.emplace("pkg.Msg", desc->full_name()); diff --git a/src/google/protobuf/compiler/plugin.pb.cc b/src/google/protobuf/compiler/plugin.pb.cc index 516be0468b..cf8b6f18c0 100644 --- a/src/google/protobuf/compiler/plugin.pb.cc +++ b/src/google/protobuf/compiler/plugin.pb.cc @@ -25,9 +25,12 @@ PROTOBUF_CONSTEXPR Version::Version( /*decltype(_impl_._has_bits_)*/{} , /*decltype(_impl_._cached_size_)*/{} , /*decltype(_impl_.suffix_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} - , /*decltype(_impl_.major_)*/0 - , /*decltype(_impl_.minor_)*/0 - , /*decltype(_impl_.patch_)*/0} {} + , /* ._impl_.major_ = */ 0 + + , /* ._impl_.minor_ = */ 0 + + , /* ._impl_.patch_ = */ 0 +} {} struct VersionDefaultTypeInternal { PROTOBUF_CONSTEXPR VersionDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {} ~VersionDefaultTypeInternal() {} @@ -80,7 +83,8 @@ PROTOBUF_CONSTEXPR CodeGeneratorResponse::CodeGeneratorResponse( , /*decltype(_impl_._cached_size_)*/{} , /*decltype(_impl_.file_)*/{} , /*decltype(_impl_.error_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} - , /*decltype(_impl_.supported_features_)*/::uint64_t{0u}} {} + , /* ._impl_.supported_features_ = */ ::uint64_t{0u} +} {} struct CodeGeneratorResponseDefaultTypeInternal { PROTOBUF_CONSTEXPR CodeGeneratorResponseDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {} ~CodeGeneratorResponseDefaultTypeInternal() {} @@ -298,9 +302,12 @@ Version::Version(const Version& from) decltype(_impl_._has_bits_){from._impl_._has_bits_} , /*decltype(_impl_._cached_size_)*/{} , decltype(_impl_.suffix_){} - , decltype(_impl_.major_){} - , decltype(_impl_.minor_){} - , decltype(_impl_.patch_){}}; + , decltype(_impl_.major_) {} + + , decltype(_impl_.minor_) {} + + , decltype(_impl_.patch_) {} + }; _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); _impl_.suffix_.InitDefault(); @@ -323,9 +330,12 @@ inline void Version::SharedCtor(::_pb::Arena* arena) { decltype(_impl_._has_bits_){} , /*decltype(_impl_._cached_size_)*/{} , decltype(_impl_.suffix_){} - , decltype(_impl_.major_){0} - , decltype(_impl_.minor_){0} - , decltype(_impl_.patch_){0} + , decltype(_impl_.major_) { 0 } + + , decltype(_impl_.minor_) { 0 } + + , decltype(_impl_.patch_) { 0 } + }; _impl_.suffix_.InitDefault(); #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING @@ -454,19 +464,22 @@ failure: // optional int32 major = 1; if (cached_has_bits & 0x00000002u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteInt32ToArray(1, this->_internal_major(), target); + target = ::_pbi::WireFormatLite::WriteInt32ToArray( + 1, this->_internal_major(), target); } // optional int32 minor = 2; if (cached_has_bits & 0x00000004u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteInt32ToArray(2, this->_internal_minor(), target); + target = ::_pbi::WireFormatLite::WriteInt32ToArray( + 2, this->_internal_minor(), target); } // optional int32 patch = 3; if (cached_has_bits & 0x00000008u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteInt32ToArray(3, this->_internal_patch(), target); + target = ::_pbi::WireFormatLite::WriteInt32ToArray( + 3, this->_internal_patch(), target); } // optional string suffix = 4; @@ -506,17 +519,20 @@ failure: // optional int32 major = 1; if (cached_has_bits & 0x00000002u) { - total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_major()); + total_size += ::_pbi::WireFormatLite::Int32SizePlusOne( + this->_internal_major()); } // optional int32 minor = 2; if (cached_has_bits & 0x00000004u) { - total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_minor()); + total_size += ::_pbi::WireFormatLite::Int32SizePlusOne( + this->_internal_minor()); } // optional int32 patch = 3; if (cached_has_bits & 0x00000008u) { - total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_patch()); + total_size += ::_pbi::WireFormatLite::Int32SizePlusOne( + this->_internal_patch()); } } @@ -1365,7 +1381,8 @@ CodeGeneratorResponse::CodeGeneratorResponse(const CodeGeneratorResponse& from) , /*decltype(_impl_._cached_size_)*/{} , decltype(_impl_.file_){from._impl_.file_} , decltype(_impl_.error_){} - , decltype(_impl_.supported_features_){}}; + , decltype(_impl_.supported_features_) {} + }; _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); _impl_.error_.InitDefault(); @@ -1387,7 +1404,8 @@ inline void CodeGeneratorResponse::SharedCtor(::_pb::Arena* arena) { , /*decltype(_impl_._cached_size_)*/{} , decltype(_impl_.file_){arena} , decltype(_impl_.error_){} - , decltype(_impl_.supported_features_){::uint64_t{0u}} + , decltype(_impl_.supported_features_) { ::uint64_t{0u} } + }; _impl_.error_.InitDefault(); #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING @@ -1518,7 +1536,8 @@ failure: // optional uint64 supported_features = 2; if (cached_has_bits & 0x00000002u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteUInt64ToArray(2, this->_internal_supported_features(), target); + target = ::_pbi::WireFormatLite::WriteUInt64ToArray( + 2, this->_internal_supported_features(), target); } // repeated .google.protobuf.compiler.CodeGeneratorResponse.File file = 15; @@ -1563,7 +1582,8 @@ failure: // optional uint64 supported_features = 2; if (cached_has_bits & 0x00000002u) { - total_size += ::_pbi::WireFormatLite::UInt64SizePlusOne(this->_internal_supported_features()); + total_size += ::_pbi::WireFormatLite::UInt64SizePlusOne( + this->_internal_supported_features()); } } @@ -1621,6 +1641,7 @@ void CodeGeneratorResponse::InternalSwap(CodeGeneratorResponse* other) { &_impl_.error_, lhs_arena, &other->_impl_.error_, rhs_arena ); + swap(_impl_.supported_features_, other->_impl_.supported_features_); } diff --git a/src/google/protobuf/compiler/plugin.pb.h b/src/google/protobuf/compiler/plugin.pb.h index 64b8aa3486..71c7e2cb9c 100644 --- a/src/google/protobuf/compiler/plugin.pb.h +++ b/src/google/protobuf/compiler/plugin.pb.h @@ -270,27 +270,33 @@ class PROTOC_EXPORT Version final : void clear_major() ; ::int32_t major() const; void set_major(::int32_t value); + private: ::int32_t _internal_major() const; void _internal_set_major(::int32_t value); + public: // optional int32 minor = 2; bool has_minor() const; void clear_minor() ; ::int32_t minor() const; void set_minor(::int32_t value); + private: ::int32_t _internal_minor() const; void _internal_set_minor(::int32_t value); + public: // optional int32 patch = 3; bool has_patch() const; void clear_patch() ; ::int32_t patch() const; void set_patch(::int32_t value); + private: ::int32_t _internal_patch() const; void _internal_set_patch(::int32_t value); + public: // @@protoc_insertion_point(class_scope:google.protobuf.compiler.Version) private: @@ -931,9 +937,11 @@ class PROTOC_EXPORT CodeGeneratorResponse final : void clear_supported_features() ; ::uint64_t supported_features() const; void set_supported_features(::uint64_t value); + private: ::uint64_t _internal_supported_features() const; void _internal_set_supported_features(::uint64_t value); + public: // @@protoc_insertion_point(class_scope:google.protobuf.compiler.CodeGeneratorResponse) private: @@ -978,21 +986,22 @@ inline void Version::clear_major() { _impl_.major_ = 0; _impl_._has_bits_[0] &= ~0x00000002u; } -inline ::int32_t Version::_internal_major() const { - return _impl_.major_; -} inline ::int32_t Version::major() const { // @@protoc_insertion_point(field_get:google.protobuf.compiler.Version.major) return _internal_major(); } -inline void Version::_internal_set_major(::int32_t value) { - _impl_._has_bits_[0] |= 0x00000002u; - _impl_.major_ = value; -} inline void Version::set_major(::int32_t value) { + ; _internal_set_major(value); // @@protoc_insertion_point(field_set:google.protobuf.compiler.Version.major) } +inline ::int32_t Version::_internal_major() const { + return _impl_.major_; +} +inline void Version::_internal_set_major(::int32_t value) { + _impl_._has_bits_[0] |= 0x00000002u; + _impl_.major_ = value; +} // optional int32 minor = 2; inline bool Version::has_minor() const { @@ -1003,21 +1012,22 @@ inline void Version::clear_minor() { _impl_.minor_ = 0; _impl_._has_bits_[0] &= ~0x00000004u; } -inline ::int32_t Version::_internal_minor() const { - return _impl_.minor_; -} inline ::int32_t Version::minor() const { // @@protoc_insertion_point(field_get:google.protobuf.compiler.Version.minor) return _internal_minor(); } -inline void Version::_internal_set_minor(::int32_t value) { - _impl_._has_bits_[0] |= 0x00000004u; - _impl_.minor_ = value; -} inline void Version::set_minor(::int32_t value) { + ; _internal_set_minor(value); // @@protoc_insertion_point(field_set:google.protobuf.compiler.Version.minor) } +inline ::int32_t Version::_internal_minor() const { + return _impl_.minor_; +} +inline void Version::_internal_set_minor(::int32_t value) { + _impl_._has_bits_[0] |= 0x00000004u; + _impl_.minor_ = value; +} // optional int32 patch = 3; inline bool Version::has_patch() const { @@ -1028,21 +1038,22 @@ inline void Version::clear_patch() { _impl_.patch_ = 0; _impl_._has_bits_[0] &= ~0x00000008u; } -inline ::int32_t Version::_internal_patch() const { - return _impl_.patch_; -} inline ::int32_t Version::patch() const { // @@protoc_insertion_point(field_get:google.protobuf.compiler.Version.patch) return _internal_patch(); } -inline void Version::_internal_set_patch(::int32_t value) { - _impl_._has_bits_[0] |= 0x00000008u; - _impl_.patch_ = value; -} inline void Version::set_patch(::int32_t value) { + ; _internal_set_patch(value); // @@protoc_insertion_point(field_set:google.protobuf.compiler.Version.patch) } +inline ::int32_t Version::_internal_patch() const { + return _impl_.patch_; +} +inline void Version::_internal_set_patch(::int32_t value) { + _impl_._has_bits_[0] |= 0x00000008u; + _impl_.patch_ = value; +} // optional string suffix = 4; inline bool Version::has_suffix() const { @@ -1732,21 +1743,22 @@ inline void CodeGeneratorResponse::clear_supported_features() { _impl_.supported_features_ = ::uint64_t{0u}; _impl_._has_bits_[0] &= ~0x00000002u; } -inline ::uint64_t CodeGeneratorResponse::_internal_supported_features() const { - return _impl_.supported_features_; -} inline ::uint64_t CodeGeneratorResponse::supported_features() const { // @@protoc_insertion_point(field_get:google.protobuf.compiler.CodeGeneratorResponse.supported_features) return _internal_supported_features(); } -inline void CodeGeneratorResponse::_internal_set_supported_features(::uint64_t value) { - _impl_._has_bits_[0] |= 0x00000002u; - _impl_.supported_features_ = value; -} inline void CodeGeneratorResponse::set_supported_features(::uint64_t value) { + ; _internal_set_supported_features(value); // @@protoc_insertion_point(field_set:google.protobuf.compiler.CodeGeneratorResponse.supported_features) } +inline ::uint64_t CodeGeneratorResponse::_internal_supported_features() const { + return _impl_.supported_features_; +} +inline void CodeGeneratorResponse::_internal_set_supported_features(::uint64_t value) { + _impl_._has_bits_[0] |= 0x00000002u; + _impl_.supported_features_ = value; +} // repeated .google.protobuf.compiler.CodeGeneratorResponse.File file = 15; inline int CodeGeneratorResponse::_internal_file_size() const { diff --git a/src/google/protobuf/descriptor.pb.cc b/src/google/protobuf/descriptor.pb.cc index 35ab4b9857..43de95d024 100644 --- a/src/google/protobuf/descriptor.pb.cc +++ b/src/google/protobuf/descriptor.pb.cc @@ -42,8 +42,10 @@ PROTOBUF_CONSTEXPR FileDescriptorProto::FileDescriptorProto( , /*decltype(_impl_.enum_type_)*/{} , /*decltype(_impl_.service_)*/{} , /*decltype(_impl_.extension_)*/{} - , /*decltype(_impl_.public_dependency_)*/{} - , /*decltype(_impl_.weak_dependency_)*/{} + , /* ._impl_.public_dependency_ = */ {} + + , /* ._impl_.weak_dependency_ = */ {} + , /*decltype(_impl_.name_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} , /*decltype(_impl_.package_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} , /*decltype(_impl_.syntax_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} @@ -65,8 +67,10 @@ PROTOBUF_CONSTEXPR DescriptorProto_ExtensionRange::DescriptorProto_ExtensionRang /*decltype(_impl_._has_bits_)*/{} , /*decltype(_impl_._cached_size_)*/{} , /*decltype(_impl_.options_)*/nullptr - , /*decltype(_impl_.start_)*/0 - , /*decltype(_impl_.end_)*/0} {} + , /* ._impl_.start_ = */ 0 + + , /* ._impl_.end_ = */ 0 +} {} struct DescriptorProto_ExtensionRangeDefaultTypeInternal { PROTOBUF_CONSTEXPR DescriptorProto_ExtensionRangeDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {} ~DescriptorProto_ExtensionRangeDefaultTypeInternal() {} @@ -81,8 +85,10 @@ PROTOBUF_CONSTEXPR DescriptorProto_ReservedRange::DescriptorProto_ReservedRange( ::_pbi::ConstantInitialized): _impl_{ /*decltype(_impl_._has_bits_)*/{} , /*decltype(_impl_._cached_size_)*/{} - , /*decltype(_impl_.start_)*/0 - , /*decltype(_impl_.end_)*/0} {} + , /* ._impl_.start_ = */ 0 + + , /* ._impl_.end_ = */ 0 +} {} struct DescriptorProto_ReservedRangeDefaultTypeInternal { PROTOBUF_CONSTEXPR DescriptorProto_ReservedRangeDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {} ~DescriptorProto_ReservedRangeDefaultTypeInternal() {} @@ -142,9 +148,12 @@ PROTOBUF_CONSTEXPR FieldDescriptorProto::FieldDescriptorProto( , /*decltype(_impl_.default_value_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} , /*decltype(_impl_.json_name_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} , /*decltype(_impl_.options_)*/nullptr - , /*decltype(_impl_.number_)*/0 - , /*decltype(_impl_.oneof_index_)*/0 - , /*decltype(_impl_.proto3_optional_)*/false + , /* ._impl_.number_ = */ 0 + + , /* ._impl_.oneof_index_ = */ 0 + + , /* ._impl_.proto3_optional_ = */ false + , /*decltype(_impl_.label_)*/1 , /*decltype(_impl_.type_)*/1} {} struct FieldDescriptorProtoDefaultTypeInternal { @@ -177,8 +186,10 @@ PROTOBUF_CONSTEXPR EnumDescriptorProto_EnumReservedRange::EnumDescriptorProto_En ::_pbi::ConstantInitialized): _impl_{ /*decltype(_impl_._has_bits_)*/{} , /*decltype(_impl_._cached_size_)*/{} - , /*decltype(_impl_.start_)*/0 - , /*decltype(_impl_.end_)*/0} {} + , /* ._impl_.start_ = */ 0 + + , /* ._impl_.end_ = */ 0 +} {} struct EnumDescriptorProto_EnumReservedRangeDefaultTypeInternal { PROTOBUF_CONSTEXPR EnumDescriptorProto_EnumReservedRangeDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {} ~EnumDescriptorProto_EnumReservedRangeDefaultTypeInternal() {} @@ -214,7 +225,8 @@ PROTOBUF_CONSTEXPR EnumValueDescriptorProto::EnumValueDescriptorProto( , /*decltype(_impl_._cached_size_)*/{} , /*decltype(_impl_.name_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} , /*decltype(_impl_.options_)*/nullptr - , /*decltype(_impl_.number_)*/0} {} + , /* ._impl_.number_ = */ 0 +} {} struct EnumValueDescriptorProtoDefaultTypeInternal { PROTOBUF_CONSTEXPR EnumValueDescriptorProtoDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {} ~EnumValueDescriptorProtoDefaultTypeInternal() {} @@ -250,8 +262,10 @@ PROTOBUF_CONSTEXPR MethodDescriptorProto::MethodDescriptorProto( , /*decltype(_impl_.input_type_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} , /*decltype(_impl_.output_type_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} , /*decltype(_impl_.options_)*/nullptr - , /*decltype(_impl_.client_streaming_)*/false - , /*decltype(_impl_.server_streaming_)*/false} {} + , /* ._impl_.client_streaming_ = */ false + + , /* ._impl_.server_streaming_ = */ false +} {} struct MethodDescriptorProtoDefaultTypeInternal { PROTOBUF_CONSTEXPR MethodDescriptorProtoDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {} ~MethodDescriptorProtoDefaultTypeInternal() {} @@ -278,16 +292,25 @@ PROTOBUF_CONSTEXPR FileOptions::FileOptions( , /*decltype(_impl_.php_namespace_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} , /*decltype(_impl_.php_metadata_namespace_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} , /*decltype(_impl_.ruby_package_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} - , /*decltype(_impl_.java_multiple_files_)*/false - , /*decltype(_impl_.java_generate_equals_and_hash_)*/false - , /*decltype(_impl_.java_string_check_utf8_)*/false - , /*decltype(_impl_.cc_generic_services_)*/false - , /*decltype(_impl_.java_generic_services_)*/false - , /*decltype(_impl_.py_generic_services_)*/false - , /*decltype(_impl_.php_generic_services_)*/false - , /*decltype(_impl_.deprecated_)*/false + , /* ._impl_.java_multiple_files_ = */ false + + , /* ._impl_.java_generate_equals_and_hash_ = */ false + + , /* ._impl_.java_string_check_utf8_ = */ false + + , /* ._impl_.cc_generic_services_ = */ false + + , /* ._impl_.java_generic_services_ = */ false + + , /* ._impl_.py_generic_services_ = */ false + + , /* ._impl_.php_generic_services_ = */ false + + , /* ._impl_.deprecated_ = */ false + , /*decltype(_impl_.optimize_for_)*/1 - , /*decltype(_impl_.cc_enable_arenas_)*/true} {} + , /* ._impl_.cc_enable_arenas_ = */ true +} {} struct FileOptionsDefaultTypeInternal { PROTOBUF_CONSTEXPR FileOptionsDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {} ~FileOptionsDefaultTypeInternal() {} @@ -304,11 +327,16 @@ PROTOBUF_CONSTEXPR MessageOptions::MessageOptions( , /*decltype(_impl_._has_bits_)*/{} , /*decltype(_impl_._cached_size_)*/{} , /*decltype(_impl_.uninterpreted_option_)*/{} - , /*decltype(_impl_.message_set_wire_format_)*/false - , /*decltype(_impl_.no_standard_descriptor_accessor_)*/false - , /*decltype(_impl_.deprecated_)*/false - , /*decltype(_impl_.map_entry_)*/false - , /*decltype(_impl_.deprecated_legacy_json_field_conflicts_)*/false} {} + , /* ._impl_.message_set_wire_format_ = */ false + + , /* ._impl_.no_standard_descriptor_accessor_ = */ false + + , /* ._impl_.deprecated_ = */ false + + , /* ._impl_.map_entry_ = */ false + + , /* ._impl_.deprecated_legacy_json_field_conflicts_ = */ false +} {} struct MessageOptionsDefaultTypeInternal { PROTOBUF_CONSTEXPR MessageOptionsDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {} ~MessageOptionsDefaultTypeInternal() {} @@ -327,12 +355,18 @@ PROTOBUF_CONSTEXPR FieldOptions::FieldOptions( , /*decltype(_impl_.uninterpreted_option_)*/{} , /*decltype(_impl_.ctype_)*/0 , /*decltype(_impl_.jstype_)*/0 - , /*decltype(_impl_.packed_)*/false - , /*decltype(_impl_.lazy_)*/false - , /*decltype(_impl_.unverified_lazy_)*/false - , /*decltype(_impl_.deprecated_)*/false - , /*decltype(_impl_.weak_)*/false - , /*decltype(_impl_.debug_redact_)*/false} {} + , /* ._impl_.packed_ = */ false + + , /* ._impl_.lazy_ = */ false + + , /* ._impl_.unverified_lazy_ = */ false + + , /* ._impl_.deprecated_ = */ false + + , /* ._impl_.weak_ = */ false + + , /* ._impl_.debug_redact_ = */ false +} {} struct FieldOptionsDefaultTypeInternal { PROTOBUF_CONSTEXPR FieldOptionsDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {} ~FieldOptionsDefaultTypeInternal() {} @@ -364,9 +398,12 @@ PROTOBUF_CONSTEXPR EnumOptions::EnumOptions( , /*decltype(_impl_._has_bits_)*/{} , /*decltype(_impl_._cached_size_)*/{} , /*decltype(_impl_.uninterpreted_option_)*/{} - , /*decltype(_impl_.allow_alias_)*/false - , /*decltype(_impl_.deprecated_)*/false - , /*decltype(_impl_.deprecated_legacy_json_field_conflicts_)*/false} {} + , /* ._impl_.allow_alias_ = */ false + + , /* ._impl_.deprecated_ = */ false + + , /* ._impl_.deprecated_legacy_json_field_conflicts_ = */ false +} {} struct EnumOptionsDefaultTypeInternal { PROTOBUF_CONSTEXPR EnumOptionsDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {} ~EnumOptionsDefaultTypeInternal() {} @@ -383,7 +420,8 @@ PROTOBUF_CONSTEXPR EnumValueOptions::EnumValueOptions( , /*decltype(_impl_._has_bits_)*/{} , /*decltype(_impl_._cached_size_)*/{} , /*decltype(_impl_.uninterpreted_option_)*/{} - , /*decltype(_impl_.deprecated_)*/false} {} + , /* ._impl_.deprecated_ = */ false +} {} struct EnumValueOptionsDefaultTypeInternal { PROTOBUF_CONSTEXPR EnumValueOptionsDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {} ~EnumValueOptionsDefaultTypeInternal() {} @@ -400,7 +438,8 @@ PROTOBUF_CONSTEXPR ServiceOptions::ServiceOptions( , /*decltype(_impl_._has_bits_)*/{} , /*decltype(_impl_._cached_size_)*/{} , /*decltype(_impl_.uninterpreted_option_)*/{} - , /*decltype(_impl_.deprecated_)*/false} {} + , /* ._impl_.deprecated_ = */ false +} {} struct ServiceOptionsDefaultTypeInternal { PROTOBUF_CONSTEXPR ServiceOptionsDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {} ~ServiceOptionsDefaultTypeInternal() {} @@ -417,7 +456,8 @@ PROTOBUF_CONSTEXPR MethodOptions::MethodOptions( , /*decltype(_impl_._has_bits_)*/{} , /*decltype(_impl_._cached_size_)*/{} , /*decltype(_impl_.uninterpreted_option_)*/{} - , /*decltype(_impl_.deprecated_)*/false + , /* ._impl_.deprecated_ = */ false + , /*decltype(_impl_.idempotency_level_)*/0} {} struct MethodOptionsDefaultTypeInternal { PROTOBUF_CONSTEXPR MethodOptionsDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {} @@ -434,7 +474,8 @@ PROTOBUF_CONSTEXPR UninterpretedOption_NamePart::UninterpretedOption_NamePart( /*decltype(_impl_._has_bits_)*/{} , /*decltype(_impl_._cached_size_)*/{} , /*decltype(_impl_.name_part_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} - , /*decltype(_impl_.is_extension_)*/false} {} + , /* ._impl_.is_extension_ = */ false +} {} struct UninterpretedOption_NamePartDefaultTypeInternal { PROTOBUF_CONSTEXPR UninterpretedOption_NamePartDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {} ~UninterpretedOption_NamePartDefaultTypeInternal() {} @@ -453,9 +494,12 @@ PROTOBUF_CONSTEXPR UninterpretedOption::UninterpretedOption( , /*decltype(_impl_.identifier_value_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} , /*decltype(_impl_.string_value_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} , /*decltype(_impl_.aggregate_value_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} - , /*decltype(_impl_.positive_int_value_)*/::uint64_t{0u} - , /*decltype(_impl_.negative_int_value_)*/::int64_t{0} - , /*decltype(_impl_.double_value_)*/0} {} + , /* ._impl_.positive_int_value_ = */ ::uint64_t{0u} + + , /* ._impl_.negative_int_value_ = */ ::int64_t{0} + + , /* ._impl_.double_value_ = */ 0 +} {} struct UninterpretedOptionDefaultTypeInternal { PROTOBUF_CONSTEXPR UninterpretedOptionDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {} ~UninterpretedOptionDefaultTypeInternal() {} @@ -470,10 +514,12 @@ PROTOBUF_CONSTEXPR SourceCodeInfo_Location::SourceCodeInfo_Location( ::_pbi::ConstantInitialized): _impl_{ /*decltype(_impl_._has_bits_)*/{} , /*decltype(_impl_._cached_size_)*/{} - , /*decltype(_impl_.path_)*/{} - , /*decltype(_impl_._path_cached_byte_size_)*/{0} - , /*decltype(_impl_.span_)*/{} - , /*decltype(_impl_._span_cached_byte_size_)*/{0} + , /* ._impl_.path_ = */ {} + ,/* _impl_._path_cached_byte_size_ = */ { 0 } + + , /* ._impl_.span_ = */ {} + ,/* _impl_._span_cached_byte_size_ = */ { 0 } + , /*decltype(_impl_.leading_detached_comments_)*/{} , /*decltype(_impl_.leading_comments_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} , /*decltype(_impl_.trailing_comments_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}}} {} @@ -505,11 +551,14 @@ PROTOBUF_CONSTEXPR GeneratedCodeInfo_Annotation::GeneratedCodeInfo_Annotation( ::_pbi::ConstantInitialized): _impl_{ /*decltype(_impl_._has_bits_)*/{} , /*decltype(_impl_._cached_size_)*/{} - , /*decltype(_impl_.path_)*/{} - , /*decltype(_impl_._path_cached_byte_size_)*/{0} + , /* ._impl_.path_ = */ {} + ,/* _impl_._path_cached_byte_size_ = */ { 0 } + , /*decltype(_impl_.source_file_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}} - , /*decltype(_impl_.begin_)*/0 - , /*decltype(_impl_.end_)*/0 + , /* ._impl_.begin_ = */ 0 + + , /* ._impl_.end_ = */ 0 + , /*decltype(_impl_.semantic_)*/0} {} struct GeneratedCodeInfo_AnnotationDefaultTypeInternal { PROTOBUF_CONSTEXPR GeneratedCodeInfo_AnnotationDefaultTypeInternal() : _instance(::_pbi::ConstantInitialized{}) {} @@ -1724,8 +1773,10 @@ FileDescriptorProto::FileDescriptorProto(const FileDescriptorProto& from) , decltype(_impl_.enum_type_){from._impl_.enum_type_} , decltype(_impl_.service_){from._impl_.service_} , decltype(_impl_.extension_){from._impl_.extension_} - , decltype(_impl_.public_dependency_){from._impl_.public_dependency_} - , decltype(_impl_.weak_dependency_){from._impl_.weak_dependency_} + , decltype(_impl_.public_dependency_) { from._impl_.public_dependency_ } + + , decltype(_impl_.weak_dependency_) { from._impl_.weak_dependency_ } + , decltype(_impl_.name_){} , decltype(_impl_.package_){} , decltype(_impl_.syntax_){} @@ -1785,8 +1836,10 @@ inline void FileDescriptorProto::SharedCtor(::_pb::Arena* arena) { , decltype(_impl_.enum_type_){arena} , decltype(_impl_.service_){arena} , decltype(_impl_.extension_){arena} - , decltype(_impl_.public_dependency_){arena} - , decltype(_impl_.weak_dependency_){arena} + , decltype(_impl_.public_dependency_) { arena } + + , decltype(_impl_.weak_dependency_) { arena } + , decltype(_impl_.name_){} , decltype(_impl_.package_){} , decltype(_impl_.syntax_){} @@ -2175,15 +2228,17 @@ failure: } // repeated int32 public_dependency = 10; - for (int i = 0, n = this->_internal_public_dependency_size(); i < n; i++) { + for (int i = 0, n = this->_internal_public_dependency_size(); i < n; ++i) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteInt32ToArray(10, this->_internal_public_dependency(i), target); + target = ::_pbi::WireFormatLite::WriteInt32ToArray( + 10, this->_internal_public_dependency(i), target); } // repeated int32 weak_dependency = 11; - for (int i = 0, n = this->_internal_weak_dependency_size(); i < n; i++) { + for (int i = 0, n = this->_internal_weak_dependency_size(); i < n; ++i) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteInt32ToArray(11, this->_internal_weak_dependency(i), target); + target = ::_pbi::WireFormatLite::WriteInt32ToArray( + 11, this->_internal_weak_dependency(i), target); } // optional string syntax = 12; @@ -2260,20 +2315,22 @@ failure: // repeated int32 public_dependency = 10; { - ::size_t data_size = ::_pbi::WireFormatLite:: - Int32Size(this->_impl_.public_dependency_); - total_size += 1 * - ::_pbi::FromIntSize(this->_internal_public_dependency_size()); - total_size += data_size; + std::size_t data_size = ::_pbi::WireFormatLite::Int32Size(this->_impl_.public_dependency_) + ; + std::size_t tag_size = std::size_t{1} * + ::_pbi::FromIntSize(this->_internal_public_dependency_size()); + ; + total_size += tag_size + data_size; } // repeated int32 weak_dependency = 11; { - ::size_t data_size = ::_pbi::WireFormatLite:: - Int32Size(this->_impl_.weak_dependency_); - total_size += 1 * - ::_pbi::FromIntSize(this->_internal_weak_dependency_size()); - total_size += data_size; + std::size_t data_size = ::_pbi::WireFormatLite::Int32Size(this->_impl_.weak_dependency_) + ; + std::size_t tag_size = std::size_t{1} * + ::_pbi::FromIntSize(this->_internal_weak_dependency_size()); + ; + total_size += tag_size + data_size; } cached_has_bits = _impl_._has_bits_[0]; @@ -2471,8 +2528,10 @@ DescriptorProto_ExtensionRange::DescriptorProto_ExtensionRange(const DescriptorP decltype(_impl_._has_bits_){from._impl_._has_bits_} , /*decltype(_impl_._cached_size_)*/{} , decltype(_impl_.options_){nullptr} - , decltype(_impl_.start_){} - , decltype(_impl_.end_){}}; + , decltype(_impl_.start_) {} + + , decltype(_impl_.end_) {} + }; _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); if ((from._impl_._has_bits_[0] & 0x00000001u) != 0) { @@ -2490,8 +2549,10 @@ inline void DescriptorProto_ExtensionRange::SharedCtor(::_pb::Arena* arena) { decltype(_impl_._has_bits_){} , /*decltype(_impl_._cached_size_)*/{} , decltype(_impl_.options_){nullptr} - , decltype(_impl_.start_){0} - , decltype(_impl_.end_){0} + , decltype(_impl_.start_) { 0 } + + , decltype(_impl_.end_) { 0 } + }; } @@ -2603,13 +2664,15 @@ failure: // optional int32 start = 1; if (cached_has_bits & 0x00000002u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteInt32ToArray(1, this->_internal_start(), target); + target = ::_pbi::WireFormatLite::WriteInt32ToArray( + 1, this->_internal_start(), target); } // optional int32 end = 2; if (cached_has_bits & 0x00000004u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteInt32ToArray(2, this->_internal_end(), target); + target = ::_pbi::WireFormatLite::WriteInt32ToArray( + 2, this->_internal_end(), target); } // optional .google.protobuf.ExtensionRangeOptions options = 3; @@ -2646,12 +2709,14 @@ failure: // optional int32 start = 1; if (cached_has_bits & 0x00000002u) { - total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_start()); + total_size += ::_pbi::WireFormatLite::Int32SizePlusOne( + this->_internal_start()); } // optional int32 end = 2; if (cached_has_bits & 0x00000004u) { - total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_end()); + total_size += ::_pbi::WireFormatLite::Int32SizePlusOne( + this->_internal_end()); } } @@ -2753,8 +2818,10 @@ inline void DescriptorProto_ReservedRange::SharedCtor(::_pb::Arena* arena) { new (&_impl_) Impl_{ decltype(_impl_._has_bits_){} , /*decltype(_impl_._cached_size_)*/{} - , decltype(_impl_.start_){0} - , decltype(_impl_.end_){0} + , decltype(_impl_.start_) { 0 } + + , decltype(_impl_.end_) { 0 } + }; } @@ -2852,13 +2919,15 @@ failure: // optional int32 start = 1; if (cached_has_bits & 0x00000001u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteInt32ToArray(1, this->_internal_start(), target); + target = ::_pbi::WireFormatLite::WriteInt32ToArray( + 1, this->_internal_start(), target); } // optional int32 end = 2; if (cached_has_bits & 0x00000002u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteInt32ToArray(2, this->_internal_end(), target); + target = ::_pbi::WireFormatLite::WriteInt32ToArray( + 2, this->_internal_end(), target); } if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { @@ -2881,12 +2950,14 @@ failure: if (cached_has_bits & 0x00000003u) { // optional int32 start = 1; if (cached_has_bits & 0x00000001u) { - total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_start()); + total_size += ::_pbi::WireFormatLite::Int32SizePlusOne( + this->_internal_start()); } // optional int32 end = 2; if (cached_has_bits & 0x00000002u) { - total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_end()); + total_size += ::_pbi::WireFormatLite::Int32SizePlusOne( + this->_internal_end()); } } @@ -3793,9 +3864,12 @@ FieldDescriptorProto::FieldDescriptorProto(const FieldDescriptorProto& from) , decltype(_impl_.default_value_){} , decltype(_impl_.json_name_){} , decltype(_impl_.options_){nullptr} - , decltype(_impl_.number_){} - , decltype(_impl_.oneof_index_){} - , decltype(_impl_.proto3_optional_){} + , decltype(_impl_.number_) {} + + , decltype(_impl_.oneof_index_) {} + + , decltype(_impl_.proto3_optional_) {} + , decltype(_impl_.label_){} , decltype(_impl_.type_){}}; @@ -3860,9 +3934,12 @@ inline void FieldDescriptorProto::SharedCtor(::_pb::Arena* arena) { , decltype(_impl_.default_value_){} , decltype(_impl_.json_name_){} , decltype(_impl_.options_){nullptr} - , decltype(_impl_.number_){0} - , decltype(_impl_.oneof_index_){0} - , decltype(_impl_.proto3_optional_){false} + , decltype(_impl_.number_) { 0 } + + , decltype(_impl_.oneof_index_) { 0 } + + , decltype(_impl_.proto3_optional_) { false } + , decltype(_impl_.label_){1} , decltype(_impl_.type_){1} }; @@ -4146,7 +4223,8 @@ failure: // optional int32 number = 3; if (cached_has_bits & 0x00000040u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteInt32ToArray(3, this->_internal_number(), target); + target = ::_pbi::WireFormatLite::WriteInt32ToArray( + 3, this->_internal_number(), target); } // optional .google.protobuf.FieldDescriptorProto.Label label = 4; @@ -4193,7 +4271,8 @@ failure: // optional int32 oneof_index = 9; if (cached_has_bits & 0x00000080u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteInt32ToArray(9, this->_internal_oneof_index(), target); + target = ::_pbi::WireFormatLite::WriteInt32ToArray( + 9, this->_internal_oneof_index(), target); } // optional string json_name = 10; @@ -4209,7 +4288,8 @@ failure: // optional bool proto3_optional = 17; if (cached_has_bits & 0x00000100u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(17, this->_internal_proto3_optional(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 17, this->_internal_proto3_optional(), target); } if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { @@ -4274,19 +4354,21 @@ failure: // optional int32 number = 3; if (cached_has_bits & 0x00000040u) { - total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_number()); + total_size += ::_pbi::WireFormatLite::Int32SizePlusOne( + this->_internal_number()); } // optional int32 oneof_index = 9; if (cached_has_bits & 0x00000080u) { - total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_oneof_index()); + total_size += ::_pbi::WireFormatLite::Int32SizePlusOne( + this->_internal_oneof_index()); } } if (cached_has_bits & 0x00000700u) { // optional bool proto3_optional = 17; if (cached_has_bits & 0x00000100u) { - total_size += 2 + 1; + total_size += 3; } // optional .google.protobuf.FieldDescriptorProto.Label label = 4; @@ -4724,8 +4806,10 @@ inline void EnumDescriptorProto_EnumReservedRange::SharedCtor(::_pb::Arena* aren new (&_impl_) Impl_{ decltype(_impl_._has_bits_){} , /*decltype(_impl_._cached_size_)*/{} - , decltype(_impl_.start_){0} - , decltype(_impl_.end_){0} + , decltype(_impl_.start_) { 0 } + + , decltype(_impl_.end_) { 0 } + }; } @@ -4823,13 +4907,15 @@ failure: // optional int32 start = 1; if (cached_has_bits & 0x00000001u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteInt32ToArray(1, this->_internal_start(), target); + target = ::_pbi::WireFormatLite::WriteInt32ToArray( + 1, this->_internal_start(), target); } // optional int32 end = 2; if (cached_has_bits & 0x00000002u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteInt32ToArray(2, this->_internal_end(), target); + target = ::_pbi::WireFormatLite::WriteInt32ToArray( + 2, this->_internal_end(), target); } if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { @@ -4852,12 +4938,14 @@ failure: if (cached_has_bits & 0x00000003u) { // optional int32 start = 1; if (cached_has_bits & 0x00000001u) { - total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_start()); + total_size += ::_pbi::WireFormatLite::Int32SizePlusOne( + this->_internal_start()); } // optional int32 end = 2; if (cached_has_bits & 0x00000002u) { - total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_end()); + total_size += ::_pbi::WireFormatLite::Int32SizePlusOne( + this->_internal_end()); } } @@ -5345,7 +5433,8 @@ EnumValueDescriptorProto::EnumValueDescriptorProto(const EnumValueDescriptorProt , /*decltype(_impl_._cached_size_)*/{} , decltype(_impl_.name_){} , decltype(_impl_.options_){nullptr} - , decltype(_impl_.number_){}}; + , decltype(_impl_.number_) {} + }; _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); _impl_.name_.InitDefault(); @@ -5370,7 +5459,8 @@ inline void EnumValueDescriptorProto::SharedCtor(::_pb::Arena* arena) { , /*decltype(_impl_._cached_size_)*/{} , decltype(_impl_.name_){} , decltype(_impl_.options_){nullptr} - , decltype(_impl_.number_){0} + , decltype(_impl_.number_) { 0 } + }; _impl_.name_.InitDefault(); #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING @@ -5501,7 +5591,8 @@ failure: // optional int32 number = 2; if (cached_has_bits & 0x00000004u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteInt32ToArray(2, this->_internal_number(), target); + target = ::_pbi::WireFormatLite::WriteInt32ToArray( + 2, this->_internal_number(), target); } // optional .google.protobuf.EnumValueOptions options = 3; @@ -5545,7 +5636,8 @@ failure: // optional int32 number = 2; if (cached_has_bits & 0x00000004u) { - total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_number()); + total_size += ::_pbi::WireFormatLite::Int32SizePlusOne( + this->_internal_number()); } } @@ -5980,8 +6072,10 @@ MethodDescriptorProto::MethodDescriptorProto(const MethodDescriptorProto& from) , decltype(_impl_.input_type_){} , decltype(_impl_.output_type_){} , decltype(_impl_.options_){nullptr} - , decltype(_impl_.client_streaming_){} - , decltype(_impl_.server_streaming_){}}; + , decltype(_impl_.client_streaming_) {} + + , decltype(_impl_.server_streaming_) {} + }; _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); _impl_.name_.InitDefault(); @@ -6026,8 +6120,10 @@ inline void MethodDescriptorProto::SharedCtor(::_pb::Arena* arena) { , decltype(_impl_.input_type_){} , decltype(_impl_.output_type_){} , decltype(_impl_.options_){nullptr} - , decltype(_impl_.client_streaming_){false} - , decltype(_impl_.server_streaming_){false} + , decltype(_impl_.client_streaming_) { false } + + , decltype(_impl_.server_streaming_) { false } + }; _impl_.name_.InitDefault(); #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING @@ -6239,13 +6335,15 @@ failure: // optional bool client_streaming = 5 [default = false]; if (cached_has_bits & 0x00000010u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(5, this->_internal_client_streaming(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 5, this->_internal_client_streaming(), target); } // optional bool server_streaming = 6 [default = false]; if (cached_has_bits & 0x00000020u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(6, this->_internal_server_streaming(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 6, this->_internal_server_streaming(), target); } if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { @@ -6296,12 +6394,12 @@ failure: // optional bool client_streaming = 5 [default = false]; if (cached_has_bits & 0x00000010u) { - total_size += 1 + 1; + total_size += 2; } // optional bool server_streaming = 6 [default = false]; if (cached_has_bits & 0x00000020u) { - total_size += 1 + 1; + total_size += 2; } } @@ -6486,16 +6584,25 @@ FileOptions::FileOptions(const FileOptions& from) , decltype(_impl_.php_namespace_){} , decltype(_impl_.php_metadata_namespace_){} , decltype(_impl_.ruby_package_){} - , decltype(_impl_.java_multiple_files_){} - , decltype(_impl_.java_generate_equals_and_hash_){} - , decltype(_impl_.java_string_check_utf8_){} - , decltype(_impl_.cc_generic_services_){} - , decltype(_impl_.java_generic_services_){} - , decltype(_impl_.py_generic_services_){} - , decltype(_impl_.php_generic_services_){} - , decltype(_impl_.deprecated_){} + , decltype(_impl_.java_multiple_files_) {} + + , decltype(_impl_.java_generate_equals_and_hash_) {} + + , decltype(_impl_.java_string_check_utf8_) {} + + , decltype(_impl_.cc_generic_services_) {} + + , decltype(_impl_.java_generic_services_) {} + + , decltype(_impl_.py_generic_services_) {} + + , decltype(_impl_.php_generic_services_) {} + + , decltype(_impl_.deprecated_) {} + , decltype(_impl_.optimize_for_){} - , decltype(_impl_.cc_enable_arenas_){}}; + , decltype(_impl_.cc_enable_arenas_) {} + }; _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); _impl_._extensions_.MergeFrom(internal_default_instance(), from._impl_._extensions_); @@ -6602,16 +6709,25 @@ inline void FileOptions::SharedCtor(::_pb::Arena* arena) { , decltype(_impl_.php_namespace_){} , decltype(_impl_.php_metadata_namespace_){} , decltype(_impl_.ruby_package_){} - , decltype(_impl_.java_multiple_files_){false} - , decltype(_impl_.java_generate_equals_and_hash_){false} - , decltype(_impl_.java_string_check_utf8_){false} - , decltype(_impl_.cc_generic_services_){false} - , decltype(_impl_.java_generic_services_){false} - , decltype(_impl_.py_generic_services_){false} - , decltype(_impl_.php_generic_services_){false} - , decltype(_impl_.deprecated_){false} + , decltype(_impl_.java_multiple_files_) { false } + + , decltype(_impl_.java_generate_equals_and_hash_) { false } + + , decltype(_impl_.java_string_check_utf8_) { false } + + , decltype(_impl_.cc_generic_services_) { false } + + , decltype(_impl_.java_generic_services_) { false } + + , decltype(_impl_.py_generic_services_) { false } + + , decltype(_impl_.php_generic_services_) { false } + + , decltype(_impl_.deprecated_) { false } + , decltype(_impl_.optimize_for_){1} - , decltype(_impl_.cc_enable_arenas_){true} + , decltype(_impl_.cc_enable_arenas_) { true } + }; _impl_.java_package_.InitDefault(); #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING @@ -7064,7 +7180,8 @@ failure: // optional bool java_multiple_files = 10 [default = false]; if (cached_has_bits & 0x00000400u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(10, this->_internal_java_multiple_files(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 10, this->_internal_java_multiple_files(), target); } // optional string go_package = 11; @@ -7080,43 +7197,50 @@ failure: // optional bool cc_generic_services = 16 [default = false]; if (cached_has_bits & 0x00002000u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(16, this->_internal_cc_generic_services(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 16, this->_internal_cc_generic_services(), target); } // optional bool java_generic_services = 17 [default = false]; if (cached_has_bits & 0x00004000u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(17, this->_internal_java_generic_services(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 17, this->_internal_java_generic_services(), target); } // optional bool py_generic_services = 18 [default = false]; if (cached_has_bits & 0x00008000u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(18, this->_internal_py_generic_services(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 18, this->_internal_py_generic_services(), target); } // optional bool java_generate_equals_and_hash = 20 [deprecated = true]; if (cached_has_bits & 0x00000800u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(20, this->_internal_java_generate_equals_and_hash(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 20, this->_internal_java_generate_equals_and_hash(), target); } // optional bool deprecated = 23 [default = false]; if (cached_has_bits & 0x00020000u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(23, this->_internal_deprecated(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 23, this->_internal_deprecated(), target); } // optional bool java_string_check_utf8 = 27 [default = false]; if (cached_has_bits & 0x00001000u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(27, this->_internal_java_string_check_utf8(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 27, this->_internal_java_string_check_utf8(), target); } // optional bool cc_enable_arenas = 31 [default = true]; if (cached_has_bits & 0x00080000u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(31, this->_internal_cc_enable_arenas(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 31, this->_internal_cc_enable_arenas(), target); } // optional string objc_class_prefix = 36; @@ -7172,7 +7296,8 @@ failure: // optional bool php_generic_services = 42 [default = false]; if (cached_has_bits & 0x00010000u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(42, this->_internal_php_generic_services(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 42, this->_internal_php_generic_services(), target); } // optional string php_metadata_namespace = 44; @@ -7308,44 +7433,44 @@ failure: // optional bool java_multiple_files = 10 [default = false]; if (cached_has_bits & 0x00000400u) { - total_size += 1 + 1; + total_size += 2; } // optional bool java_generate_equals_and_hash = 20 [deprecated = true]; if (cached_has_bits & 0x00000800u) { - total_size += 2 + 1; + total_size += 3; } // optional bool java_string_check_utf8 = 27 [default = false]; if (cached_has_bits & 0x00001000u) { - total_size += 2 + 1; + total_size += 3; } // optional bool cc_generic_services = 16 [default = false]; if (cached_has_bits & 0x00002000u) { - total_size += 2 + 1; + total_size += 3; } // optional bool java_generic_services = 17 [default = false]; if (cached_has_bits & 0x00004000u) { - total_size += 2 + 1; + total_size += 3; } // optional bool py_generic_services = 18 [default = false]; if (cached_has_bits & 0x00008000u) { - total_size += 2 + 1; + total_size += 3; } } if (cached_has_bits & 0x000f0000u) { // optional bool php_generic_services = 42 [default = false]; if (cached_has_bits & 0x00010000u) { - total_size += 2 + 1; + total_size += 3; } // optional bool deprecated = 23 [default = false]; if (cached_has_bits & 0x00020000u) { - total_size += 2 + 1; + total_size += 3; } // optional .google.protobuf.FileOptions.OptimizeMode optimize_for = 9 [default = SPEED]; @@ -7356,7 +7481,7 @@ failure: // optional bool cc_enable_arenas = 31 [default = true]; if (cached_has_bits & 0x00080000u) { - total_size += 2 + 1; + total_size += 3; } } @@ -7567,11 +7692,16 @@ MessageOptions::MessageOptions(const MessageOptions& from) , decltype(_impl_._has_bits_){from._impl_._has_bits_} , /*decltype(_impl_._cached_size_)*/{} , decltype(_impl_.uninterpreted_option_){from._impl_.uninterpreted_option_} - , decltype(_impl_.message_set_wire_format_){} - , decltype(_impl_.no_standard_descriptor_accessor_){} - , decltype(_impl_.deprecated_){} - , decltype(_impl_.map_entry_){} - , decltype(_impl_.deprecated_legacy_json_field_conflicts_){}}; + , decltype(_impl_.message_set_wire_format_) {} + + , decltype(_impl_.no_standard_descriptor_accessor_) {} + + , decltype(_impl_.deprecated_) {} + + , decltype(_impl_.map_entry_) {} + + , decltype(_impl_.deprecated_legacy_json_field_conflicts_) {} + }; _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); _impl_._extensions_.MergeFrom(internal_default_instance(), from._impl_._extensions_); @@ -7588,11 +7718,16 @@ inline void MessageOptions::SharedCtor(::_pb::Arena* arena) { , decltype(_impl_._has_bits_){} , /*decltype(_impl_._cached_size_)*/{} , decltype(_impl_.uninterpreted_option_){arena} - , decltype(_impl_.message_set_wire_format_){false} - , decltype(_impl_.no_standard_descriptor_accessor_){false} - , decltype(_impl_.deprecated_){false} - , decltype(_impl_.map_entry_){false} - , decltype(_impl_.deprecated_legacy_json_field_conflicts_){false} + , decltype(_impl_.message_set_wire_format_) { false } + + , decltype(_impl_.no_standard_descriptor_accessor_) { false } + + , decltype(_impl_.deprecated_) { false } + + , decltype(_impl_.map_entry_) { false } + + , decltype(_impl_.deprecated_legacy_json_field_conflicts_) { false } + }; } @@ -7743,31 +7878,36 @@ failure: // optional bool message_set_wire_format = 1 [default = false]; if (cached_has_bits & 0x00000001u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(1, this->_internal_message_set_wire_format(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 1, this->_internal_message_set_wire_format(), target); } // optional bool no_standard_descriptor_accessor = 2 [default = false]; if (cached_has_bits & 0x00000002u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(2, this->_internal_no_standard_descriptor_accessor(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 2, this->_internal_no_standard_descriptor_accessor(), target); } // optional bool deprecated = 3 [default = false]; if (cached_has_bits & 0x00000004u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(3, this->_internal_deprecated(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 3, this->_internal_deprecated(), target); } // optional bool map_entry = 7; if (cached_has_bits & 0x00000008u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(7, this->_internal_map_entry(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 7, this->_internal_map_entry(), target); } // optional bool deprecated_legacy_json_field_conflicts = 11 [deprecated = true]; if (cached_has_bits & 0x00000010u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(11, this->_internal_deprecated_legacy_json_field_conflicts(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 11, this->_internal_deprecated_legacy_json_field_conflicts(), target); } // repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999; @@ -7811,27 +7951,27 @@ failure: if (cached_has_bits & 0x0000001fu) { // optional bool message_set_wire_format = 1 [default = false]; if (cached_has_bits & 0x00000001u) { - total_size += 1 + 1; + total_size += 2; } // optional bool no_standard_descriptor_accessor = 2 [default = false]; if (cached_has_bits & 0x00000002u) { - total_size += 1 + 1; + total_size += 2; } // optional bool deprecated = 3 [default = false]; if (cached_has_bits & 0x00000004u) { - total_size += 1 + 1; + total_size += 2; } // optional bool map_entry = 7; if (cached_has_bits & 0x00000008u) { - total_size += 1 + 1; + total_size += 2; } // optional bool deprecated_legacy_json_field_conflicts = 11 [deprecated = true]; if (cached_has_bits & 0x00000010u) { - total_size += 1 + 1; + total_size += 2; } } @@ -7961,12 +8101,18 @@ FieldOptions::FieldOptions(const FieldOptions& from) , decltype(_impl_.uninterpreted_option_){from._impl_.uninterpreted_option_} , decltype(_impl_.ctype_){} , decltype(_impl_.jstype_){} - , decltype(_impl_.packed_){} - , decltype(_impl_.lazy_){} - , decltype(_impl_.unverified_lazy_){} - , decltype(_impl_.deprecated_){} - , decltype(_impl_.weak_){} - , decltype(_impl_.debug_redact_){}}; + , decltype(_impl_.packed_) {} + + , decltype(_impl_.lazy_) {} + + , decltype(_impl_.unverified_lazy_) {} + + , decltype(_impl_.deprecated_) {} + + , decltype(_impl_.weak_) {} + + , decltype(_impl_.debug_redact_) {} + }; _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); _impl_._extensions_.MergeFrom(internal_default_instance(), from._impl_._extensions_); @@ -7985,12 +8131,18 @@ inline void FieldOptions::SharedCtor(::_pb::Arena* arena) { , decltype(_impl_.uninterpreted_option_){arena} , decltype(_impl_.ctype_){0} , decltype(_impl_.jstype_){0} - , decltype(_impl_.packed_){false} - , decltype(_impl_.lazy_){false} - , decltype(_impl_.unverified_lazy_){false} - , decltype(_impl_.deprecated_){false} - , decltype(_impl_.weak_){false} - , decltype(_impl_.debug_redact_){false} + , decltype(_impl_.packed_) { false } + + , decltype(_impl_.lazy_) { false } + + , decltype(_impl_.unverified_lazy_) { false } + + , decltype(_impl_.deprecated_) { false } + + , decltype(_impl_.weak_) { false } + + , decltype(_impl_.debug_redact_) { false } + }; } @@ -8186,19 +8338,22 @@ failure: // optional bool packed = 2; if (cached_has_bits & 0x00000004u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(2, this->_internal_packed(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 2, this->_internal_packed(), target); } // optional bool deprecated = 3 [default = false]; if (cached_has_bits & 0x00000020u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(3, this->_internal_deprecated(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 3, this->_internal_deprecated(), target); } // optional bool lazy = 5 [default = false]; if (cached_has_bits & 0x00000008u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(5, this->_internal_lazy(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 5, this->_internal_lazy(), target); } // optional .google.protobuf.FieldOptions.JSType jstype = 6 [default = JS_NORMAL]; @@ -8211,19 +8366,22 @@ failure: // optional bool weak = 10 [default = false]; if (cached_has_bits & 0x00000040u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(10, this->_internal_weak(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 10, this->_internal_weak(), target); } // optional bool unverified_lazy = 15 [default = false]; if (cached_has_bits & 0x00000010u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(15, this->_internal_unverified_lazy(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 15, this->_internal_unverified_lazy(), target); } // optional bool debug_redact = 16 [default = false]; if (cached_has_bits & 0x00000080u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(16, this->_internal_debug_redact(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 16, this->_internal_debug_redact(), target); } // repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999; @@ -8279,32 +8437,32 @@ failure: // optional bool packed = 2; if (cached_has_bits & 0x00000004u) { - total_size += 1 + 1; + total_size += 2; } // optional bool lazy = 5 [default = false]; if (cached_has_bits & 0x00000008u) { - total_size += 1 + 1; + total_size += 2; } // optional bool unverified_lazy = 15 [default = false]; if (cached_has_bits & 0x00000010u) { - total_size += 1 + 1; + total_size += 2; } // optional bool deprecated = 3 [default = false]; if (cached_has_bits & 0x00000020u) { - total_size += 1 + 1; + total_size += 2; } // optional bool weak = 10 [default = false]; if (cached_has_bits & 0x00000040u) { - total_size += 1 + 1; + total_size += 2; } // optional bool debug_redact = 16 [default = false]; if (cached_has_bits & 0x00000080u) { - total_size += 2 + 1; + total_size += 3; } } @@ -8632,9 +8790,12 @@ EnumOptions::EnumOptions(const EnumOptions& from) , decltype(_impl_._has_bits_){from._impl_._has_bits_} , /*decltype(_impl_._cached_size_)*/{} , decltype(_impl_.uninterpreted_option_){from._impl_.uninterpreted_option_} - , decltype(_impl_.allow_alias_){} - , decltype(_impl_.deprecated_){} - , decltype(_impl_.deprecated_legacy_json_field_conflicts_){}}; + , decltype(_impl_.allow_alias_) {} + + , decltype(_impl_.deprecated_) {} + + , decltype(_impl_.deprecated_legacy_json_field_conflicts_) {} + }; _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); _impl_._extensions_.MergeFrom(internal_default_instance(), from._impl_._extensions_); @@ -8651,9 +8812,12 @@ inline void EnumOptions::SharedCtor(::_pb::Arena* arena) { , decltype(_impl_._has_bits_){} , /*decltype(_impl_._cached_size_)*/{} , decltype(_impl_.uninterpreted_option_){arena} - , decltype(_impl_.allow_alias_){false} - , decltype(_impl_.deprecated_){false} - , decltype(_impl_.deprecated_legacy_json_field_conflicts_){false} + , decltype(_impl_.allow_alias_) { false } + + , decltype(_impl_.deprecated_) { false } + + , decltype(_impl_.deprecated_legacy_json_field_conflicts_) { false } + }; } @@ -8781,19 +8945,22 @@ failure: // optional bool allow_alias = 2; if (cached_has_bits & 0x00000001u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(2, this->_internal_allow_alias(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 2, this->_internal_allow_alias(), target); } // optional bool deprecated = 3 [default = false]; if (cached_has_bits & 0x00000002u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(3, this->_internal_deprecated(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 3, this->_internal_deprecated(), target); } // optional bool deprecated_legacy_json_field_conflicts = 6 [deprecated = true]; if (cached_has_bits & 0x00000004u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(6, this->_internal_deprecated_legacy_json_field_conflicts(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 6, this->_internal_deprecated_legacy_json_field_conflicts(), target); } // repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999; @@ -8837,17 +9004,17 @@ failure: if (cached_has_bits & 0x00000007u) { // optional bool allow_alias = 2; if (cached_has_bits & 0x00000001u) { - total_size += 1 + 1; + total_size += 2; } // optional bool deprecated = 3 [default = false]; if (cached_has_bits & 0x00000002u) { - total_size += 1 + 1; + total_size += 2; } // optional bool deprecated_legacy_json_field_conflicts = 6 [deprecated = true]; if (cached_has_bits & 0x00000004u) { - total_size += 1 + 1; + total_size += 2; } } @@ -8948,7 +9115,8 @@ EnumValueOptions::EnumValueOptions(const EnumValueOptions& from) , decltype(_impl_._has_bits_){from._impl_._has_bits_} , /*decltype(_impl_._cached_size_)*/{} , decltype(_impl_.uninterpreted_option_){from._impl_.uninterpreted_option_} - , decltype(_impl_.deprecated_){}}; + , decltype(_impl_.deprecated_) {} + }; _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); _impl_._extensions_.MergeFrom(internal_default_instance(), from._impl_._extensions_); @@ -8963,7 +9131,8 @@ inline void EnumValueOptions::SharedCtor(::_pb::Arena* arena) { , decltype(_impl_._has_bits_){} , /*decltype(_impl_._cached_size_)*/{} , decltype(_impl_.uninterpreted_option_){arena} - , decltype(_impl_.deprecated_){false} + , decltype(_impl_.deprecated_) { false } + }; } @@ -9069,7 +9238,8 @@ failure: // optional bool deprecated = 1 [default = false]; if (cached_has_bits & 0x00000001u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(1, this->_internal_deprecated(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 1, this->_internal_deprecated(), target); } // repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999; @@ -9112,7 +9282,7 @@ failure: // optional bool deprecated = 1 [default = false]; cached_has_bits = _impl_._has_bits_[0]; if (cached_has_bits & 0x00000001u) { - total_size += 1 + 1; + total_size += 2; } return MaybeComputeUnknownFieldsSize(total_size, &_impl_._cached_size_); @@ -9164,6 +9334,7 @@ void EnumValueOptions::InternalSwap(EnumValueOptions* other) { _internal_metadata_.InternalSwap(&other->_internal_metadata_); swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]); _impl_.uninterpreted_option_.InternalSwap(&other->_impl_.uninterpreted_option_); + swap(_impl_.deprecated_, other->_impl_.deprecated_); } @@ -9197,7 +9368,8 @@ ServiceOptions::ServiceOptions(const ServiceOptions& from) , decltype(_impl_._has_bits_){from._impl_._has_bits_} , /*decltype(_impl_._cached_size_)*/{} , decltype(_impl_.uninterpreted_option_){from._impl_.uninterpreted_option_} - , decltype(_impl_.deprecated_){}}; + , decltype(_impl_.deprecated_) {} + }; _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); _impl_._extensions_.MergeFrom(internal_default_instance(), from._impl_._extensions_); @@ -9212,7 +9384,8 @@ inline void ServiceOptions::SharedCtor(::_pb::Arena* arena) { , decltype(_impl_._has_bits_){} , /*decltype(_impl_._cached_size_)*/{} , decltype(_impl_.uninterpreted_option_){arena} - , decltype(_impl_.deprecated_){false} + , decltype(_impl_.deprecated_) { false } + }; } @@ -9318,7 +9491,8 @@ failure: // optional bool deprecated = 33 [default = false]; if (cached_has_bits & 0x00000001u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(33, this->_internal_deprecated(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 33, this->_internal_deprecated(), target); } // repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999; @@ -9361,7 +9535,7 @@ failure: // optional bool deprecated = 33 [default = false]; cached_has_bits = _impl_._has_bits_[0]; if (cached_has_bits & 0x00000001u) { - total_size += 2 + 1; + total_size += 3; } return MaybeComputeUnknownFieldsSize(total_size, &_impl_._cached_size_); @@ -9413,6 +9587,7 @@ void ServiceOptions::InternalSwap(ServiceOptions* other) { _internal_metadata_.InternalSwap(&other->_internal_metadata_); swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]); _impl_.uninterpreted_option_.InternalSwap(&other->_impl_.uninterpreted_option_); + swap(_impl_.deprecated_, other->_impl_.deprecated_); } @@ -9449,7 +9624,8 @@ MethodOptions::MethodOptions(const MethodOptions& from) , decltype(_impl_._has_bits_){from._impl_._has_bits_} , /*decltype(_impl_._cached_size_)*/{} , decltype(_impl_.uninterpreted_option_){from._impl_.uninterpreted_option_} - , decltype(_impl_.deprecated_){} + , decltype(_impl_.deprecated_) {} + , decltype(_impl_.idempotency_level_){}}; _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); @@ -9467,7 +9643,8 @@ inline void MethodOptions::SharedCtor(::_pb::Arena* arena) { , decltype(_impl_._has_bits_){} , /*decltype(_impl_._cached_size_)*/{} , decltype(_impl_.uninterpreted_option_){arena} - , decltype(_impl_.deprecated_){false} + , decltype(_impl_.deprecated_) { false } + , decltype(_impl_.idempotency_level_){0} }; } @@ -9593,7 +9770,8 @@ failure: // optional bool deprecated = 33 [default = false]; if (cached_has_bits & 0x00000001u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(33, this->_internal_deprecated(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 33, this->_internal_deprecated(), target); } // optional .google.protobuf.MethodOptions.IdempotencyLevel idempotency_level = 34 [default = IDEMPOTENCY_UNKNOWN]; @@ -9644,7 +9822,7 @@ failure: if (cached_has_bits & 0x00000003u) { // optional bool deprecated = 33 [default = false]; if (cached_has_bits & 0x00000001u) { - total_size += 2 + 1; + total_size += 3; } // optional .google.protobuf.MethodOptions.IdempotencyLevel idempotency_level = 34 [default = IDEMPOTENCY_UNKNOWN]; @@ -9753,7 +9931,8 @@ UninterpretedOption_NamePart::UninterpretedOption_NamePart(const UninterpretedOp decltype(_impl_._has_bits_){from._impl_._has_bits_} , /*decltype(_impl_._cached_size_)*/{} , decltype(_impl_.name_part_){} - , decltype(_impl_.is_extension_){}}; + , decltype(_impl_.is_extension_) {} + }; _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); _impl_.name_part_.InitDefault(); @@ -9774,7 +9953,8 @@ inline void UninterpretedOption_NamePart::SharedCtor(::_pb::Arena* arena) { decltype(_impl_._has_bits_){} , /*decltype(_impl_._cached_size_)*/{} , decltype(_impl_.name_part_){} - , decltype(_impl_.is_extension_){false} + , decltype(_impl_.is_extension_) { false } + }; _impl_.name_part_.InitDefault(); #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING @@ -9889,7 +10069,8 @@ failure: // required bool is_extension = 2; if (cached_has_bits & 0x00000002u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteBoolToArray(2, this->_internal_is_extension(), target); + target = ::_pbi::WireFormatLite::WriteBoolToArray( + 2, this->_internal_is_extension(), target); } if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { @@ -9913,7 +10094,7 @@ failure: if ((_impl_._has_bits_[0] & 0x00000002u) != 0) { // required bool is_extension = 2; - total_size += 1 + 1; + total_size += 2; } return total_size; @@ -9929,7 +10110,7 @@ failure: this->_internal_name_part()); // required bool is_extension = 2; - total_size += 1 + 1; + total_size += 2; } else { total_size += RequiredFieldsByteSizeFallback(); @@ -9991,6 +10172,7 @@ void UninterpretedOption_NamePart::InternalSwap(UninterpretedOption_NamePart* ot &_impl_.name_part_, lhs_arena, &other->_impl_.name_part_, rhs_arena ); + swap(_impl_.is_extension_, other->_impl_.is_extension_); } @@ -10041,9 +10223,12 @@ UninterpretedOption::UninterpretedOption(const UninterpretedOption& from) , decltype(_impl_.identifier_value_){} , decltype(_impl_.string_value_){} , decltype(_impl_.aggregate_value_){} - , decltype(_impl_.positive_int_value_){} - , decltype(_impl_.negative_int_value_){} - , decltype(_impl_.double_value_){}}; + , decltype(_impl_.positive_int_value_) {} + + , decltype(_impl_.negative_int_value_) {} + + , decltype(_impl_.double_value_) {} + }; _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); _impl_.identifier_value_.InitDefault(); @@ -10085,9 +10270,12 @@ inline void UninterpretedOption::SharedCtor(::_pb::Arena* arena) { , decltype(_impl_.identifier_value_){} , decltype(_impl_.string_value_){} , decltype(_impl_.aggregate_value_){} - , decltype(_impl_.positive_int_value_){::uint64_t{0u}} - , decltype(_impl_.negative_int_value_){::int64_t{0}} - , decltype(_impl_.double_value_){0} + , decltype(_impl_.positive_int_value_) { ::uint64_t{0u} } + + , decltype(_impl_.negative_int_value_) { ::int64_t{0} } + + , decltype(_impl_.double_value_) { 0 } + }; _impl_.identifier_value_.InitDefault(); #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING @@ -10291,19 +10479,22 @@ failure: // optional uint64 positive_int_value = 4; if (cached_has_bits & 0x00000008u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteUInt64ToArray(4, this->_internal_positive_int_value(), target); + target = ::_pbi::WireFormatLite::WriteUInt64ToArray( + 4, this->_internal_positive_int_value(), target); } // optional int64 negative_int_value = 5; if (cached_has_bits & 0x00000010u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteInt64ToArray(5, this->_internal_negative_int_value(), target); + target = ::_pbi::WireFormatLite::WriteInt64ToArray( + 5, this->_internal_negative_int_value(), target); } // optional double double_value = 6; if (cached_has_bits & 0x00000020u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteDoubleToArray(6, this->_internal_double_value(), target); + target = ::_pbi::WireFormatLite::WriteDoubleToArray( + 6, this->_internal_double_value(), target); } // optional bytes string_value = 7; @@ -10370,17 +10561,19 @@ failure: // optional uint64 positive_int_value = 4; if (cached_has_bits & 0x00000008u) { - total_size += ::_pbi::WireFormatLite::UInt64SizePlusOne(this->_internal_positive_int_value()); + total_size += ::_pbi::WireFormatLite::UInt64SizePlusOne( + this->_internal_positive_int_value()); } // optional int64 negative_int_value = 5; if (cached_has_bits & 0x00000010u) { - total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_negative_int_value()); + total_size += ::_pbi::WireFormatLite::Int64SizePlusOne( + this->_internal_negative_int_value()); } // optional double double_value = 6; if (cached_has_bits & 0x00000020u) { - total_size += 1 + 8; + total_size += 9; } } @@ -10499,10 +10692,12 @@ SourceCodeInfo_Location::SourceCodeInfo_Location(const SourceCodeInfo_Location& new (&_impl_) Impl_{ decltype(_impl_._has_bits_){from._impl_._has_bits_} , /*decltype(_impl_._cached_size_)*/{} - , decltype(_impl_.path_){from._impl_.path_} - , /*decltype(_impl_._path_cached_byte_size_)*/{0} - , decltype(_impl_.span_){from._impl_.span_} - , /*decltype(_impl_._span_cached_byte_size_)*/{0} + , decltype(_impl_.path_) { from._impl_.path_ } + ,/* _impl_._path_cached_byte_size_ = */ { 0 } + + , decltype(_impl_.span_) { from._impl_.span_ } + ,/* _impl_._span_cached_byte_size_ = */ { 0 } + , decltype(_impl_.leading_detached_comments_){from._impl_.leading_detached_comments_} , decltype(_impl_.leading_comments_){} , decltype(_impl_.trailing_comments_){}}; @@ -10532,10 +10727,12 @@ inline void SourceCodeInfo_Location::SharedCtor(::_pb::Arena* arena) { new (&_impl_) Impl_{ decltype(_impl_._has_bits_){} , /*decltype(_impl_._cached_size_)*/{} - , decltype(_impl_.path_){arena} - , /*decltype(_impl_._path_cached_byte_size_)*/{0} - , decltype(_impl_.span_){arena} - , /*decltype(_impl_._span_cached_byte_size_)*/{0} + , decltype(_impl_.path_) { arena } + ,/* _impl_._path_cached_byte_size_ = */ { 0 } + + , decltype(_impl_.span_) { arena } + ,/* _impl_._span_cached_byte_size_ = */ { 0 } + , decltype(_impl_.leading_detached_comments_){arena} , decltype(_impl_.leading_comments_){} , decltype(_impl_.trailing_comments_){} @@ -10703,8 +10900,8 @@ failure: { int byte_size = _impl_._path_cached_byte_size_.Get(); if (byte_size > 0) { - target = stream->WriteInt32Packed( - 1, _internal_path(), byte_size, target); + target = stream->WriteInt32Packed(1, _internal_path(), + byte_size, target); } } @@ -10712,8 +10909,8 @@ failure: { int byte_size = _impl_._span_cached_byte_size_.Get(); if (byte_size > 0) { - target = stream->WriteInt32Packed( - 2, _internal_span(), byte_size, target); + target = stream->WriteInt32Packed(2, _internal_span(), + byte_size, target); } } @@ -10766,28 +10963,28 @@ failure: // repeated int32 path = 1 [packed = true]; { - ::size_t data_size = ::_pbi::WireFormatLite:: - Int32Size(this->_impl_.path_); - if (data_size > 0) { - total_size += 1 + - ::_pbi::WireFormatLite::Int32Size(static_cast<::int32_t>(data_size)); - } - int cached_size = ::_pbi::ToCachedSize(data_size); - _impl_._path_cached_byte_size_.Set(cached_size); - total_size += data_size; + std::size_t data_size = ::_pbi::WireFormatLite::Int32Size(this->_impl_.path_) + ; + _impl_._path_cached_byte_size_.Set(::_pbi::ToCachedSize(data_size)); + std::size_t tag_size = data_size == 0 + ? 0 + : 1 + ::_pbi::WireFormatLite::Int32Size( + static_cast(data_size)) + ; + total_size += tag_size + data_size; } // repeated int32 span = 2 [packed = true]; { - ::size_t data_size = ::_pbi::WireFormatLite:: - Int32Size(this->_impl_.span_); - if (data_size > 0) { - total_size += 1 + - ::_pbi::WireFormatLite::Int32Size(static_cast<::int32_t>(data_size)); - } - int cached_size = ::_pbi::ToCachedSize(data_size); - _impl_._span_cached_byte_size_.Set(cached_size); - total_size += data_size; + std::size_t data_size = ::_pbi::WireFormatLite::Int32Size(this->_impl_.span_) + ; + _impl_._span_cached_byte_size_.Set(::_pbi::ToCachedSize(data_size)); + std::size_t tag_size = data_size == 0 + ? 0 + : 1 + ::_pbi::WireFormatLite::Int32Size( + static_cast(data_size)) + ; + total_size += tag_size + data_size; } // repeated string leading_detached_comments = 6; @@ -11097,11 +11294,14 @@ GeneratedCodeInfo_Annotation::GeneratedCodeInfo_Annotation(const GeneratedCodeIn new (&_impl_) Impl_{ decltype(_impl_._has_bits_){from._impl_._has_bits_} , /*decltype(_impl_._cached_size_)*/{} - , decltype(_impl_.path_){from._impl_.path_} - , /*decltype(_impl_._path_cached_byte_size_)*/{0} + , decltype(_impl_.path_) { from._impl_.path_ } + ,/* _impl_._path_cached_byte_size_ = */ { 0 } + , decltype(_impl_.source_file_){} - , decltype(_impl_.begin_){} - , decltype(_impl_.end_){} + , decltype(_impl_.begin_) {} + + , decltype(_impl_.end_) {} + , decltype(_impl_.semantic_){}}; _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_); @@ -11124,11 +11324,14 @@ inline void GeneratedCodeInfo_Annotation::SharedCtor(::_pb::Arena* arena) { new (&_impl_) Impl_{ decltype(_impl_._has_bits_){} , /*decltype(_impl_._cached_size_)*/{} - , decltype(_impl_.path_){arena} - , /*decltype(_impl_._path_cached_byte_size_)*/{0} + , decltype(_impl_.path_) { arena } + ,/* _impl_._path_cached_byte_size_ = */ { 0 } + , decltype(_impl_.source_file_){} - , decltype(_impl_.begin_){0} - , decltype(_impl_.end_){0} + , decltype(_impl_.begin_) { 0 } + + , decltype(_impl_.end_) { 0 } + , decltype(_impl_.semantic_){0} }; _impl_.source_file_.InitDefault(); @@ -11276,8 +11479,8 @@ failure: { int byte_size = _impl_._path_cached_byte_size_.Get(); if (byte_size > 0) { - target = stream->WriteInt32Packed( - 1, _internal_path(), byte_size, target); + target = stream->WriteInt32Packed(1, _internal_path(), + byte_size, target); } } @@ -11295,13 +11498,15 @@ failure: // optional int32 begin = 3; if (cached_has_bits & 0x00000002u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteInt32ToArray(3, this->_internal_begin(), target); + target = ::_pbi::WireFormatLite::WriteInt32ToArray( + 3, this->_internal_begin(), target); } // optional int32 end = 4; if (cached_has_bits & 0x00000004u) { target = stream->EnsureSpace(target); - target = ::_pbi::WireFormatLite::WriteInt32ToArray(4, this->_internal_end(), target); + target = ::_pbi::WireFormatLite::WriteInt32ToArray( + 4, this->_internal_end(), target); } // optional .google.protobuf.GeneratedCodeInfo.Annotation.Semantic semantic = 5; @@ -11329,15 +11534,15 @@ failure: // repeated int32 path = 1 [packed = true]; { - ::size_t data_size = ::_pbi::WireFormatLite:: - Int32Size(this->_impl_.path_); - if (data_size > 0) { - total_size += 1 + - ::_pbi::WireFormatLite::Int32Size(static_cast<::int32_t>(data_size)); - } - int cached_size = ::_pbi::ToCachedSize(data_size); - _impl_._path_cached_byte_size_.Set(cached_size); - total_size += data_size; + std::size_t data_size = ::_pbi::WireFormatLite::Int32Size(this->_impl_.path_) + ; + _impl_._path_cached_byte_size_.Set(::_pbi::ToCachedSize(data_size)); + std::size_t tag_size = data_size == 0 + ? 0 + : 1 + ::_pbi::WireFormatLite::Int32Size( + static_cast(data_size)) + ; + total_size += tag_size + data_size; } cached_has_bits = _impl_._has_bits_[0]; @@ -11351,12 +11556,14 @@ failure: // optional int32 begin = 3; if (cached_has_bits & 0x00000002u) { - total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_begin()); + total_size += ::_pbi::WireFormatLite::Int32SizePlusOne( + this->_internal_begin()); } // optional int32 end = 4; if (cached_has_bits & 0x00000004u) { - total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_end()); + total_size += ::_pbi::WireFormatLite::Int32SizePlusOne( + this->_internal_end()); } // optional .google.protobuf.GeneratedCodeInfo.Annotation.Semantic semantic = 5; diff --git a/src/google/protobuf/descriptor.pb.h b/src/google/protobuf/descriptor.pb.h index e4b1cdcea2..328c4e3985 100644 --- a/src/google/protobuf/descriptor.pb.h +++ b/src/google/protobuf/descriptor.pb.h @@ -822,21 +822,19 @@ class PROTOBUF_EXPORT FileDescriptorProto final : public: void clear_public_dependency() ; + ::int32_t public_dependency(int index) const; + void set_public_dependency(int index, ::int32_t value); + void add_public_dependency(::int32_t value); + const ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>& public_dependency() const; + ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>* mutable_public_dependency(); + private: ::int32_t _internal_public_dependency(int index) const; - const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >& - _internal_public_dependency() const; void _internal_add_public_dependency(::int32_t value); - ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >* - _internal_mutable_public_dependency(); + const ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>& _internal_public_dependency() const; + ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>* _internal_mutable_public_dependency(); + public: - ::int32_t public_dependency(int index) const; - void set_public_dependency(int index, ::int32_t value); - void add_public_dependency(::int32_t value); - const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >& - public_dependency() const; - ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >* - mutable_public_dependency(); // repeated int32 weak_dependency = 11; int weak_dependency_size() const; private: @@ -844,21 +842,19 @@ class PROTOBUF_EXPORT FileDescriptorProto final : public: void clear_weak_dependency() ; + ::int32_t weak_dependency(int index) const; + void set_weak_dependency(int index, ::int32_t value); + void add_weak_dependency(::int32_t value); + const ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>& weak_dependency() const; + ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>* mutable_weak_dependency(); + private: ::int32_t _internal_weak_dependency(int index) const; - const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >& - _internal_weak_dependency() const; void _internal_add_weak_dependency(::int32_t value); - ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >* - _internal_mutable_weak_dependency(); + const ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>& _internal_weak_dependency() const; + ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>* _internal_mutable_weak_dependency(); + public: - ::int32_t weak_dependency(int index) const; - void set_weak_dependency(int index, ::int32_t value); - void add_weak_dependency(::int32_t value); - const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >& - weak_dependency() const; - ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >* - mutable_weak_dependency(); // optional string name = 1; bool has_name() const; void clear_name() ; @@ -958,8 +954,8 @@ class PROTOBUF_EXPORT FileDescriptorProto final : ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::PROTOBUF_NAMESPACE_ID::EnumDescriptorProto > enum_type_; ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::PROTOBUF_NAMESPACE_ID::ServiceDescriptorProto > service_; ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField< ::PROTOBUF_NAMESPACE_ID::FieldDescriptorProto > extension_; - ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t > public_dependency_; - ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t > weak_dependency_; + ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t> public_dependency_; + ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t> weak_dependency_; ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr name_; ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr package_; ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr syntax_; @@ -1121,18 +1117,22 @@ class PROTOBUF_EXPORT DescriptorProto_ExtensionRange final : void clear_start() ; ::int32_t start() const; void set_start(::int32_t value); + private: ::int32_t _internal_start() const; void _internal_set_start(::int32_t value); + public: // optional int32 end = 2; bool has_end() const; void clear_end() ; ::int32_t end() const; void set_end(::int32_t value); + private: ::int32_t _internal_end() const; void _internal_set_end(::int32_t value); + public: // @@protoc_insertion_point(class_scope:google.protobuf.DescriptorProto.ExtensionRange) private: @@ -1287,18 +1287,22 @@ class PROTOBUF_EXPORT DescriptorProto_ReservedRange final : void clear_start() ; ::int32_t start() const; void set_start(::int32_t value); + private: ::int32_t _internal_start() const; void _internal_set_start(::int32_t value); + public: // optional int32 end = 2; bool has_end() const; void clear_end() ; ::int32_t end() const; void set_end(::int32_t value); + private: ::int32_t _internal_end() const; void _internal_set_end(::int32_t value); + public: // @@protoc_insertion_point(class_scope:google.protobuf.DescriptorProto.ReservedRange) private: @@ -2263,27 +2267,33 @@ class PROTOBUF_EXPORT FieldDescriptorProto final : void clear_number() ; ::int32_t number() const; void set_number(::int32_t value); + private: ::int32_t _internal_number() const; void _internal_set_number(::int32_t value); + public: // optional int32 oneof_index = 9; bool has_oneof_index() const; void clear_oneof_index() ; ::int32_t oneof_index() const; void set_oneof_index(::int32_t value); + private: ::int32_t _internal_oneof_index() const; void _internal_set_oneof_index(::int32_t value); + public: // optional bool proto3_optional = 17; bool has_proto3_optional() const; void clear_proto3_optional() ; bool proto3_optional() const; void set_proto3_optional(bool value); + private: bool _internal_proto3_optional() const; void _internal_set_proto3_optional(bool value); + public: // optional .google.protobuf.FieldDescriptorProto.Label label = 4; bool has_label() const; @@ -2639,18 +2649,22 @@ class PROTOBUF_EXPORT EnumDescriptorProto_EnumReservedRange final : void clear_start() ; ::int32_t start() const; void set_start(::int32_t value); + private: ::int32_t _internal_start() const; void _internal_set_start(::int32_t value); + public: // optional int32 end = 2; bool has_end() const; void clear_end() ; ::int32_t end() const; void set_end(::int32_t value); + private: ::int32_t _internal_end() const; void _internal_set_end(::int32_t value); + public: // @@protoc_insertion_point(class_scope:google.protobuf.EnumDescriptorProto.EnumReservedRange) private: @@ -3078,9 +3092,11 @@ class PROTOBUF_EXPORT EnumValueDescriptorProto final : void clear_number() ; ::int32_t number() const; void set_number(::int32_t value); + private: ::int32_t _internal_number() const; void _internal_set_number(::int32_t value); + public: // @@protoc_insertion_point(class_scope:google.protobuf.EnumValueDescriptorProto) private: @@ -3490,18 +3506,22 @@ class PROTOBUF_EXPORT MethodDescriptorProto final : void clear_client_streaming() ; bool client_streaming() const; void set_client_streaming(bool value); + private: bool _internal_client_streaming() const; void _internal_set_client_streaming(bool value); + public: // optional bool server_streaming = 6 [default = false]; bool has_server_streaming() const; void clear_server_streaming() ; bool server_streaming() const; void set_server_streaming(bool value); + private: bool _internal_server_streaming() const; void _internal_set_server_streaming(bool value); + public: // @@protoc_insertion_point(class_scope:google.protobuf.MethodDescriptorProto) private: @@ -3857,72 +3877,88 @@ class PROTOBUF_EXPORT FileOptions final : void clear_java_multiple_files() ; bool java_multiple_files() const; void set_java_multiple_files(bool value); + private: bool _internal_java_multiple_files() const; void _internal_set_java_multiple_files(bool value); + public: // optional bool java_generate_equals_and_hash = 20 [deprecated = true]; PROTOBUF_DEPRECATED bool has_java_generate_equals_and_hash() const; PROTOBUF_DEPRECATED void clear_java_generate_equals_and_hash() ; PROTOBUF_DEPRECATED bool java_generate_equals_and_hash() const; PROTOBUF_DEPRECATED void set_java_generate_equals_and_hash(bool value); + private: bool _internal_java_generate_equals_and_hash() const; void _internal_set_java_generate_equals_and_hash(bool value); + public: // optional bool java_string_check_utf8 = 27 [default = false]; bool has_java_string_check_utf8() const; void clear_java_string_check_utf8() ; bool java_string_check_utf8() const; void set_java_string_check_utf8(bool value); + private: bool _internal_java_string_check_utf8() const; void _internal_set_java_string_check_utf8(bool value); + public: // optional bool cc_generic_services = 16 [default = false]; bool has_cc_generic_services() const; void clear_cc_generic_services() ; bool cc_generic_services() const; void set_cc_generic_services(bool value); + private: bool _internal_cc_generic_services() const; void _internal_set_cc_generic_services(bool value); + public: // optional bool java_generic_services = 17 [default = false]; bool has_java_generic_services() const; void clear_java_generic_services() ; bool java_generic_services() const; void set_java_generic_services(bool value); + private: bool _internal_java_generic_services() const; void _internal_set_java_generic_services(bool value); + public: // optional bool py_generic_services = 18 [default = false]; bool has_py_generic_services() const; void clear_py_generic_services() ; bool py_generic_services() const; void set_py_generic_services(bool value); + private: bool _internal_py_generic_services() const; void _internal_set_py_generic_services(bool value); + public: // optional bool php_generic_services = 42 [default = false]; bool has_php_generic_services() const; void clear_php_generic_services() ; bool php_generic_services() const; void set_php_generic_services(bool value); + private: bool _internal_php_generic_services() const; void _internal_set_php_generic_services(bool value); + public: // optional bool deprecated = 23 [default = false]; bool has_deprecated() const; void clear_deprecated() ; bool deprecated() const; void set_deprecated(bool value); + private: bool _internal_deprecated() const; void _internal_set_deprecated(bool value); + public: // optional .google.protobuf.FileOptions.OptimizeMode optimize_for = 9 [default = SPEED]; bool has_optimize_for() const; @@ -3938,9 +3974,11 @@ class PROTOBUF_EXPORT FileOptions final : void clear_cc_enable_arenas() ; bool cc_enable_arenas() const; void set_cc_enable_arenas(bool value); + private: bool _internal_cc_enable_arenas() const; void _internal_set_cc_enable_arenas(bool value); + public: template @@ -4288,45 +4326,55 @@ class PROTOBUF_EXPORT MessageOptions final : void clear_message_set_wire_format() ; bool message_set_wire_format() const; void set_message_set_wire_format(bool value); + private: bool _internal_message_set_wire_format() const; void _internal_set_message_set_wire_format(bool value); + public: // optional bool no_standard_descriptor_accessor = 2 [default = false]; bool has_no_standard_descriptor_accessor() const; void clear_no_standard_descriptor_accessor() ; bool no_standard_descriptor_accessor() const; void set_no_standard_descriptor_accessor(bool value); + private: bool _internal_no_standard_descriptor_accessor() const; void _internal_set_no_standard_descriptor_accessor(bool value); + public: // optional bool deprecated = 3 [default = false]; bool has_deprecated() const; void clear_deprecated() ; bool deprecated() const; void set_deprecated(bool value); + private: bool _internal_deprecated() const; void _internal_set_deprecated(bool value); + public: // optional bool map_entry = 7; bool has_map_entry() const; void clear_map_entry() ; bool map_entry() const; void set_map_entry(bool value); + private: bool _internal_map_entry() const; void _internal_set_map_entry(bool value); + public: // optional bool deprecated_legacy_json_field_conflicts = 11 [deprecated = true]; PROTOBUF_DEPRECATED bool has_deprecated_legacy_json_field_conflicts() const; PROTOBUF_DEPRECATED void clear_deprecated_legacy_json_field_conflicts() ; PROTOBUF_DEPRECATED bool deprecated_legacy_json_field_conflicts() const; PROTOBUF_DEPRECATED void set_deprecated_legacy_json_field_conflicts(bool value); + private: bool _internal_deprecated_legacy_json_field_conflicts() const; void _internal_set_deprecated_legacy_json_field_conflicts(bool value); + public: template @@ -4722,54 +4770,66 @@ class PROTOBUF_EXPORT FieldOptions final : void clear_packed() ; bool packed() const; void set_packed(bool value); + private: bool _internal_packed() const; void _internal_set_packed(bool value); + public: // optional bool lazy = 5 [default = false]; bool has_lazy() const; void clear_lazy() ; bool lazy() const; void set_lazy(bool value); + private: bool _internal_lazy() const; void _internal_set_lazy(bool value); + public: // optional bool unverified_lazy = 15 [default = false]; bool has_unverified_lazy() const; void clear_unverified_lazy() ; bool unverified_lazy() const; void set_unverified_lazy(bool value); + private: bool _internal_unverified_lazy() const; void _internal_set_unverified_lazy(bool value); + public: // optional bool deprecated = 3 [default = false]; bool has_deprecated() const; void clear_deprecated() ; bool deprecated() const; void set_deprecated(bool value); + private: bool _internal_deprecated() const; void _internal_set_deprecated(bool value); + public: // optional bool weak = 10 [default = false]; bool has_weak() const; void clear_weak() ; bool weak() const; void set_weak(bool value); + private: bool _internal_weak() const; void _internal_set_weak(bool value); + public: // optional bool debug_redact = 16 [default = false]; bool has_debug_redact() const; void clear_debug_redact() ; bool debug_redact() const; void set_debug_redact(bool value); + private: bool _internal_debug_redact() const; void _internal_set_debug_redact(bool value); + public: template @@ -5418,27 +5478,33 @@ class PROTOBUF_EXPORT EnumOptions final : void clear_allow_alias() ; bool allow_alias() const; void set_allow_alias(bool value); + private: bool _internal_allow_alias() const; void _internal_set_allow_alias(bool value); + public: // optional bool deprecated = 3 [default = false]; bool has_deprecated() const; void clear_deprecated() ; bool deprecated() const; void set_deprecated(bool value); + private: bool _internal_deprecated() const; void _internal_set_deprecated(bool value); + public: // optional bool deprecated_legacy_json_field_conflicts = 6 [deprecated = true]; PROTOBUF_DEPRECATED bool has_deprecated_legacy_json_field_conflicts() const; PROTOBUF_DEPRECATED void clear_deprecated_legacy_json_field_conflicts() ; PROTOBUF_DEPRECATED bool deprecated_legacy_json_field_conflicts() const; PROTOBUF_DEPRECATED void set_deprecated_legacy_json_field_conflicts(bool value); + private: bool _internal_deprecated_legacy_json_field_conflicts() const; void _internal_set_deprecated_legacy_json_field_conflicts(bool value); + public: template @@ -5765,9 +5831,11 @@ class PROTOBUF_EXPORT EnumValueOptions final : void clear_deprecated() ; bool deprecated() const; void set_deprecated(bool value); + private: bool _internal_deprecated() const; void _internal_set_deprecated(bool value); + public: template @@ -6092,9 +6160,11 @@ class PROTOBUF_EXPORT ServiceOptions final : void clear_deprecated() ; bool deprecated() const; void set_deprecated(bool value); + private: bool _internal_deprecated() const; void _internal_set_deprecated(bool value); + public: template @@ -6441,9 +6511,11 @@ class PROTOBUF_EXPORT MethodOptions final : void clear_deprecated() ; bool deprecated() const; void set_deprecated(bool value); + private: bool _internal_deprecated() const; void _internal_set_deprecated(bool value); + public: // optional .google.protobuf.MethodOptions.IdempotencyLevel idempotency_level = 34 [default = IDEMPOTENCY_UNKNOWN]; bool has_idempotency_level() const; @@ -6774,9 +6846,11 @@ class PROTOBUF_EXPORT UninterpretedOption_NamePart final : void clear_is_extension() ; bool is_extension() const; void set_is_extension(bool value); + private: bool _internal_is_extension() const; void _internal_set_is_extension(bool value); + public: // @@protoc_insertion_point(class_scope:google.protobuf.UninterpretedOption.NamePart) private: @@ -7000,27 +7074,33 @@ class PROTOBUF_EXPORT UninterpretedOption final : void clear_positive_int_value() ; ::uint64_t positive_int_value() const; void set_positive_int_value(::uint64_t value); + private: ::uint64_t _internal_positive_int_value() const; void _internal_set_positive_int_value(::uint64_t value); + public: // optional int64 negative_int_value = 5; bool has_negative_int_value() const; void clear_negative_int_value() ; ::int64_t negative_int_value() const; void set_negative_int_value(::int64_t value); + private: ::int64_t _internal_negative_int_value() const; void _internal_set_negative_int_value(::int64_t value); + public: // optional double double_value = 6; bool has_double_value() const; void clear_double_value() ; double double_value() const; void set_double_value(double value); + private: double _internal_double_value() const; void _internal_set_double_value(double value); + public: // @@protoc_insertion_point(class_scope:google.protobuf.UninterpretedOption) private: @@ -7184,21 +7264,19 @@ class PROTOBUF_EXPORT SourceCodeInfo_Location final : public: void clear_path() ; + ::int32_t path(int index) const; + void set_path(int index, ::int32_t value); + void add_path(::int32_t value); + const ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>& path() const; + ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>* mutable_path(); + private: ::int32_t _internal_path(int index) const; - const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >& - _internal_path() const; void _internal_add_path(::int32_t value); - ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >* - _internal_mutable_path(); + const ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>& _internal_path() const; + ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>* _internal_mutable_path(); + public: - ::int32_t path(int index) const; - void set_path(int index, ::int32_t value); - void add_path(::int32_t value); - const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >& - path() const; - ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >* - mutable_path(); // repeated int32 span = 2 [packed = true]; int span_size() const; private: @@ -7206,21 +7284,19 @@ class PROTOBUF_EXPORT SourceCodeInfo_Location final : public: void clear_span() ; + ::int32_t span(int index) const; + void set_span(int index, ::int32_t value); + void add_span(::int32_t value); + const ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>& span() const; + ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>* mutable_span(); + private: ::int32_t _internal_span(int index) const; - const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >& - _internal_span() const; void _internal_add_span(::int32_t value); - ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >* - _internal_mutable_span(); + const ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>& _internal_span() const; + ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>* _internal_mutable_span(); + public: - ::int32_t span(int index) const; - void set_span(int index, ::int32_t value); - void add_span(::int32_t value); - const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >& - span() const; - ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >* - mutable_span(); // repeated string leading_detached_comments = 6; int leading_detached_comments_size() const; private: @@ -7285,9 +7361,9 @@ class PROTOBUF_EXPORT SourceCodeInfo_Location final : struct Impl_ { ::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_; mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_; - ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t > path_; + ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t> path_; mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _path_cached_byte_size_; - ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t > span_; + ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t> span_; mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _span_cached_byte_size_; ::PROTOBUF_NAMESPACE_ID::RepeatedPtrField leading_detached_comments_; ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr leading_comments_; @@ -7622,21 +7698,19 @@ class PROTOBUF_EXPORT GeneratedCodeInfo_Annotation final : public: void clear_path() ; + ::int32_t path(int index) const; + void set_path(int index, ::int32_t value); + void add_path(::int32_t value); + const ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>& path() const; + ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>* mutable_path(); + private: ::int32_t _internal_path(int index) const; - const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >& - _internal_path() const; void _internal_add_path(::int32_t value); - ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >* - _internal_mutable_path(); + const ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>& _internal_path() const; + ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>* _internal_mutable_path(); + public: - ::int32_t path(int index) const; - void set_path(int index, ::int32_t value); - void add_path(::int32_t value); - const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >& - path() const; - ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >* - mutable_path(); // optional string source_file = 2; bool has_source_file() const; void clear_source_file() ; @@ -7656,18 +7730,22 @@ class PROTOBUF_EXPORT GeneratedCodeInfo_Annotation final : void clear_begin() ; ::int32_t begin() const; void set_begin(::int32_t value); + private: ::int32_t _internal_begin() const; void _internal_set_begin(::int32_t value); + public: // optional int32 end = 4; bool has_end() const; void clear_end() ; ::int32_t end() const; void set_end(::int32_t value); + private: ::int32_t _internal_end() const; void _internal_set_end(::int32_t value); + public: // optional .google.protobuf.GeneratedCodeInfo.Annotation.Semantic semantic = 5; bool has_semantic() const; @@ -7688,7 +7766,7 @@ class PROTOBUF_EXPORT GeneratedCodeInfo_Annotation final : struct Impl_ { ::PROTOBUF_NAMESPACE_ID::internal::HasBits<1> _has_bits_; mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_; - ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t > path_; + ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t> path_; mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _path_cached_byte_size_; ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr source_file_; ::int32_t begin_; @@ -8140,9 +8218,6 @@ inline int FileDescriptorProto::public_dependency_size() const { inline void FileDescriptorProto::clear_public_dependency() { _impl_.public_dependency_.Clear(); } -inline ::int32_t FileDescriptorProto::_internal_public_dependency(int index) const { - return _impl_.public_dependency_.Get(index); -} inline ::int32_t FileDescriptorProto::public_dependency(int index) const { // @@protoc_insertion_point(field_get:google.protobuf.FileDescriptorProto.public_dependency) return _internal_public_dependency(index); @@ -8151,32 +8226,30 @@ inline void FileDescriptorProto::set_public_dependency(int index, ::int32_t valu _impl_.public_dependency_.Set(index, value); // @@protoc_insertion_point(field_set:google.protobuf.FileDescriptorProto.public_dependency) } -inline void FileDescriptorProto::_internal_add_public_dependency(::int32_t value) { - _impl_.public_dependency_.Add(value); -} inline void FileDescriptorProto::add_public_dependency(::int32_t value) { _internal_add_public_dependency(value); // @@protoc_insertion_point(field_add:google.protobuf.FileDescriptorProto.public_dependency) } -inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >& -FileDescriptorProto::_internal_public_dependency() const { - return _impl_.public_dependency_; -} -inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >& -FileDescriptorProto::public_dependency() const { +inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>& FileDescriptorProto::public_dependency() const { // @@protoc_insertion_point(field_list:google.protobuf.FileDescriptorProto.public_dependency) return _internal_public_dependency(); } -inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >* -FileDescriptorProto::_internal_mutable_public_dependency() { - return &_impl_.public_dependency_; -} -inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >* -FileDescriptorProto::mutable_public_dependency() { +inline ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>* FileDescriptorProto::mutable_public_dependency() { // @@protoc_insertion_point(field_mutable_list:google.protobuf.FileDescriptorProto.public_dependency) return _internal_mutable_public_dependency(); } +inline ::int32_t FileDescriptorProto::_internal_public_dependency(int index) const { + return _impl_.public_dependency_.Get(index); +} +inline void FileDescriptorProto::_internal_add_public_dependency(::int32_t value) { _impl_.public_dependency_.Add(value); } +inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>& FileDescriptorProto::_internal_public_dependency() const { + return _impl_.public_dependency_; +} +inline ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>* FileDescriptorProto::_internal_mutable_public_dependency() { + return &_impl_.public_dependency_; +} + // repeated int32 weak_dependency = 11; inline int FileDescriptorProto::_internal_weak_dependency_size() const { return _impl_.weak_dependency_.size(); @@ -8187,9 +8260,6 @@ inline int FileDescriptorProto::weak_dependency_size() const { inline void FileDescriptorProto::clear_weak_dependency() { _impl_.weak_dependency_.Clear(); } -inline ::int32_t FileDescriptorProto::_internal_weak_dependency(int index) const { - return _impl_.weak_dependency_.Get(index); -} inline ::int32_t FileDescriptorProto::weak_dependency(int index) const { // @@protoc_insertion_point(field_get:google.protobuf.FileDescriptorProto.weak_dependency) return _internal_weak_dependency(index); @@ -8198,32 +8268,30 @@ inline void FileDescriptorProto::set_weak_dependency(int index, ::int32_t value) _impl_.weak_dependency_.Set(index, value); // @@protoc_insertion_point(field_set:google.protobuf.FileDescriptorProto.weak_dependency) } -inline void FileDescriptorProto::_internal_add_weak_dependency(::int32_t value) { - _impl_.weak_dependency_.Add(value); -} inline void FileDescriptorProto::add_weak_dependency(::int32_t value) { _internal_add_weak_dependency(value); // @@protoc_insertion_point(field_add:google.protobuf.FileDescriptorProto.weak_dependency) } -inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >& -FileDescriptorProto::_internal_weak_dependency() const { - return _impl_.weak_dependency_; -} -inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >& -FileDescriptorProto::weak_dependency() const { +inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>& FileDescriptorProto::weak_dependency() const { // @@protoc_insertion_point(field_list:google.protobuf.FileDescriptorProto.weak_dependency) return _internal_weak_dependency(); } -inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >* -FileDescriptorProto::_internal_mutable_weak_dependency() { - return &_impl_.weak_dependency_; -} -inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >* -FileDescriptorProto::mutable_weak_dependency() { +inline ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>* FileDescriptorProto::mutable_weak_dependency() { // @@protoc_insertion_point(field_mutable_list:google.protobuf.FileDescriptorProto.weak_dependency) return _internal_mutable_weak_dependency(); } +inline ::int32_t FileDescriptorProto::_internal_weak_dependency(int index) const { + return _impl_.weak_dependency_.Get(index); +} +inline void FileDescriptorProto::_internal_add_weak_dependency(::int32_t value) { _impl_.weak_dependency_.Add(value); } +inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>& FileDescriptorProto::_internal_weak_dependency() const { + return _impl_.weak_dependency_; +} +inline ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>* FileDescriptorProto::_internal_mutable_weak_dependency() { + return &_impl_.weak_dependency_; +} + // repeated .google.protobuf.DescriptorProto message_type = 4; inline int FileDescriptorProto::_internal_message_type_size() const { return _impl_.message_type_.size(); @@ -8697,21 +8765,22 @@ inline void DescriptorProto_ExtensionRange::clear_start() { _impl_.start_ = 0; _impl_._has_bits_[0] &= ~0x00000002u; } -inline ::int32_t DescriptorProto_ExtensionRange::_internal_start() const { - return _impl_.start_; -} inline ::int32_t DescriptorProto_ExtensionRange::start() const { // @@protoc_insertion_point(field_get:google.protobuf.DescriptorProto.ExtensionRange.start) return _internal_start(); } -inline void DescriptorProto_ExtensionRange::_internal_set_start(::int32_t value) { - _impl_._has_bits_[0] |= 0x00000002u; - _impl_.start_ = value; -} inline void DescriptorProto_ExtensionRange::set_start(::int32_t value) { + ; _internal_set_start(value); // @@protoc_insertion_point(field_set:google.protobuf.DescriptorProto.ExtensionRange.start) } +inline ::int32_t DescriptorProto_ExtensionRange::_internal_start() const { + return _impl_.start_; +} +inline void DescriptorProto_ExtensionRange::_internal_set_start(::int32_t value) { + _impl_._has_bits_[0] |= 0x00000002u; + _impl_.start_ = value; +} // optional int32 end = 2; inline bool DescriptorProto_ExtensionRange::has_end() const { @@ -8722,21 +8791,22 @@ inline void DescriptorProto_ExtensionRange::clear_end() { _impl_.end_ = 0; _impl_._has_bits_[0] &= ~0x00000004u; } -inline ::int32_t DescriptorProto_ExtensionRange::_internal_end() const { - return _impl_.end_; -} inline ::int32_t DescriptorProto_ExtensionRange::end() const { // @@protoc_insertion_point(field_get:google.protobuf.DescriptorProto.ExtensionRange.end) return _internal_end(); } -inline void DescriptorProto_ExtensionRange::_internal_set_end(::int32_t value) { - _impl_._has_bits_[0] |= 0x00000004u; - _impl_.end_ = value; -} inline void DescriptorProto_ExtensionRange::set_end(::int32_t value) { + ; _internal_set_end(value); // @@protoc_insertion_point(field_set:google.protobuf.DescriptorProto.ExtensionRange.end) } +inline ::int32_t DescriptorProto_ExtensionRange::_internal_end() const { + return _impl_.end_; +} +inline void DescriptorProto_ExtensionRange::_internal_set_end(::int32_t value) { + _impl_._has_bits_[0] |= 0x00000004u; + _impl_.end_ = value; +} // optional .google.protobuf.ExtensionRangeOptions options = 3; inline bool DescriptorProto_ExtensionRange::has_options() const { @@ -8838,21 +8908,22 @@ inline void DescriptorProto_ReservedRange::clear_start() { _impl_.start_ = 0; _impl_._has_bits_[0] &= ~0x00000001u; } -inline ::int32_t DescriptorProto_ReservedRange::_internal_start() const { - return _impl_.start_; -} inline ::int32_t DescriptorProto_ReservedRange::start() const { // @@protoc_insertion_point(field_get:google.protobuf.DescriptorProto.ReservedRange.start) return _internal_start(); } -inline void DescriptorProto_ReservedRange::_internal_set_start(::int32_t value) { - _impl_._has_bits_[0] |= 0x00000001u; - _impl_.start_ = value; -} inline void DescriptorProto_ReservedRange::set_start(::int32_t value) { + ; _internal_set_start(value); // @@protoc_insertion_point(field_set:google.protobuf.DescriptorProto.ReservedRange.start) } +inline ::int32_t DescriptorProto_ReservedRange::_internal_start() const { + return _impl_.start_; +} +inline void DescriptorProto_ReservedRange::_internal_set_start(::int32_t value) { + _impl_._has_bits_[0] |= 0x00000001u; + _impl_.start_ = value; +} // optional int32 end = 2; inline bool DescriptorProto_ReservedRange::has_end() const { @@ -8863,21 +8934,22 @@ inline void DescriptorProto_ReservedRange::clear_end() { _impl_.end_ = 0; _impl_._has_bits_[0] &= ~0x00000002u; } -inline ::int32_t DescriptorProto_ReservedRange::_internal_end() const { - return _impl_.end_; -} inline ::int32_t DescriptorProto_ReservedRange::end() const { // @@protoc_insertion_point(field_get:google.protobuf.DescriptorProto.ReservedRange.end) return _internal_end(); } -inline void DescriptorProto_ReservedRange::_internal_set_end(::int32_t value) { - _impl_._has_bits_[0] |= 0x00000002u; - _impl_.end_ = value; -} inline void DescriptorProto_ReservedRange::set_end(::int32_t value) { + ; _internal_set_end(value); // @@protoc_insertion_point(field_set:google.protobuf.DescriptorProto.ReservedRange.end) } +inline ::int32_t DescriptorProto_ReservedRange::_internal_end() const { + return _impl_.end_; +} +inline void DescriptorProto_ReservedRange::_internal_set_end(::int32_t value) { + _impl_._has_bits_[0] |= 0x00000002u; + _impl_.end_ = value; +} // ------------------------------------------------------------------- @@ -9514,21 +9586,22 @@ inline void FieldDescriptorProto::clear_number() { _impl_.number_ = 0; _impl_._has_bits_[0] &= ~0x00000040u; } -inline ::int32_t FieldDescriptorProto::_internal_number() const { - return _impl_.number_; -} inline ::int32_t FieldDescriptorProto::number() const { // @@protoc_insertion_point(field_get:google.protobuf.FieldDescriptorProto.number) return _internal_number(); } -inline void FieldDescriptorProto::_internal_set_number(::int32_t value) { - _impl_._has_bits_[0] |= 0x00000040u; - _impl_.number_ = value; -} inline void FieldDescriptorProto::set_number(::int32_t value) { + ; _internal_set_number(value); // @@protoc_insertion_point(field_set:google.protobuf.FieldDescriptorProto.number) } +inline ::int32_t FieldDescriptorProto::_internal_number() const { + return _impl_.number_; +} +inline void FieldDescriptorProto::_internal_set_number(::int32_t value) { + _impl_._has_bits_[0] |= 0x00000040u; + _impl_.number_ = value; +} // optional .google.protobuf.FieldDescriptorProto.Label label = 4; inline bool FieldDescriptorProto::has_label() const { @@ -9780,21 +9853,22 @@ inline void FieldDescriptorProto::clear_oneof_index() { _impl_.oneof_index_ = 0; _impl_._has_bits_[0] &= ~0x00000080u; } -inline ::int32_t FieldDescriptorProto::_internal_oneof_index() const { - return _impl_.oneof_index_; -} inline ::int32_t FieldDescriptorProto::oneof_index() const { // @@protoc_insertion_point(field_get:google.protobuf.FieldDescriptorProto.oneof_index) return _internal_oneof_index(); } -inline void FieldDescriptorProto::_internal_set_oneof_index(::int32_t value) { - _impl_._has_bits_[0] |= 0x00000080u; - _impl_.oneof_index_ = value; -} inline void FieldDescriptorProto::set_oneof_index(::int32_t value) { + ; _internal_set_oneof_index(value); // @@protoc_insertion_point(field_set:google.protobuf.FieldDescriptorProto.oneof_index) } +inline ::int32_t FieldDescriptorProto::_internal_oneof_index() const { + return _impl_.oneof_index_; +} +inline void FieldDescriptorProto::_internal_set_oneof_index(::int32_t value) { + _impl_._has_bits_[0] |= 0x00000080u; + _impl_.oneof_index_ = value; +} // optional string json_name = 10; inline bool FieldDescriptorProto::has_json_name() const { @@ -9955,26 +10029,27 @@ inline void FieldDescriptorProto::clear_proto3_optional() { _impl_.proto3_optional_ = false; _impl_._has_bits_[0] &= ~0x00000100u; } -inline bool FieldDescriptorProto::_internal_proto3_optional() const { - return _impl_.proto3_optional_; -} inline bool FieldDescriptorProto::proto3_optional() const { // @@protoc_insertion_point(field_get:google.protobuf.FieldDescriptorProto.proto3_optional) return _internal_proto3_optional(); } -inline void FieldDescriptorProto::_internal_set_proto3_optional(bool value) { - _impl_._has_bits_[0] |= 0x00000100u; - _impl_.proto3_optional_ = value; -} inline void FieldDescriptorProto::set_proto3_optional(bool value) { + ; _internal_set_proto3_optional(value); // @@protoc_insertion_point(field_set:google.protobuf.FieldDescriptorProto.proto3_optional) } - -// ------------------------------------------------------------------- - -// OneofDescriptorProto - +inline bool FieldDescriptorProto::_internal_proto3_optional() const { + return _impl_.proto3_optional_; +} +inline void FieldDescriptorProto::_internal_set_proto3_optional(bool value) { + _impl_._has_bits_[0] |= 0x00000100u; + _impl_.proto3_optional_ = value; +} + +// ------------------------------------------------------------------- + +// OneofDescriptorProto + // optional string name = 1; inline bool OneofDescriptorProto::has_name() const { bool value = (_impl_._has_bits_[0] & 0x00000001u) != 0; @@ -10138,21 +10213,22 @@ inline void EnumDescriptorProto_EnumReservedRange::clear_start() { _impl_.start_ = 0; _impl_._has_bits_[0] &= ~0x00000001u; } -inline ::int32_t EnumDescriptorProto_EnumReservedRange::_internal_start() const { - return _impl_.start_; -} inline ::int32_t EnumDescriptorProto_EnumReservedRange::start() const { // @@protoc_insertion_point(field_get:google.protobuf.EnumDescriptorProto.EnumReservedRange.start) return _internal_start(); } -inline void EnumDescriptorProto_EnumReservedRange::_internal_set_start(::int32_t value) { - _impl_._has_bits_[0] |= 0x00000001u; - _impl_.start_ = value; -} inline void EnumDescriptorProto_EnumReservedRange::set_start(::int32_t value) { + ; _internal_set_start(value); // @@protoc_insertion_point(field_set:google.protobuf.EnumDescriptorProto.EnumReservedRange.start) } +inline ::int32_t EnumDescriptorProto_EnumReservedRange::_internal_start() const { + return _impl_.start_; +} +inline void EnumDescriptorProto_EnumReservedRange::_internal_set_start(::int32_t value) { + _impl_._has_bits_[0] |= 0x00000001u; + _impl_.start_ = value; +} // optional int32 end = 2; inline bool EnumDescriptorProto_EnumReservedRange::has_end() const { @@ -10163,21 +10239,22 @@ inline void EnumDescriptorProto_EnumReservedRange::clear_end() { _impl_.end_ = 0; _impl_._has_bits_[0] &= ~0x00000002u; } -inline ::int32_t EnumDescriptorProto_EnumReservedRange::_internal_end() const { - return _impl_.end_; -} inline ::int32_t EnumDescriptorProto_EnumReservedRange::end() const { // @@protoc_insertion_point(field_get:google.protobuf.EnumDescriptorProto.EnumReservedRange.end) return _internal_end(); } -inline void EnumDescriptorProto_EnumReservedRange::_internal_set_end(::int32_t value) { - _impl_._has_bits_[0] |= 0x00000002u; - _impl_.end_ = value; -} inline void EnumDescriptorProto_EnumReservedRange::set_end(::int32_t value) { + ; _internal_set_end(value); // @@protoc_insertion_point(field_set:google.protobuf.EnumDescriptorProto.EnumReservedRange.end) } +inline ::int32_t EnumDescriptorProto_EnumReservedRange::_internal_end() const { + return _impl_.end_; +} +inline void EnumDescriptorProto_EnumReservedRange::_internal_set_end(::int32_t value) { + _impl_._has_bits_[0] |= 0x00000002u; + _impl_.end_ = value; +} // ------------------------------------------------------------------- @@ -10570,21 +10647,22 @@ inline void EnumValueDescriptorProto::clear_number() { _impl_.number_ = 0; _impl_._has_bits_[0] &= ~0x00000004u; } -inline ::int32_t EnumValueDescriptorProto::_internal_number() const { - return _impl_.number_; -} inline ::int32_t EnumValueDescriptorProto::number() const { // @@protoc_insertion_point(field_get:google.protobuf.EnumValueDescriptorProto.number) return _internal_number(); } -inline void EnumValueDescriptorProto::_internal_set_number(::int32_t value) { - _impl_._has_bits_[0] |= 0x00000004u; - _impl_.number_ = value; -} inline void EnumValueDescriptorProto::set_number(::int32_t value) { + ; _internal_set_number(value); // @@protoc_insertion_point(field_set:google.protobuf.EnumValueDescriptorProto.number) } +inline ::int32_t EnumValueDescriptorProto::_internal_number() const { + return _impl_.number_; +} +inline void EnumValueDescriptorProto::_internal_set_number(::int32_t value) { + _impl_._has_bits_[0] |= 0x00000004u; + _impl_.number_ = value; +} // optional .google.protobuf.EnumValueOptions options = 3; inline bool EnumValueDescriptorProto::has_options() const { @@ -11156,21 +11234,22 @@ inline void MethodDescriptorProto::clear_client_streaming() { _impl_.client_streaming_ = false; _impl_._has_bits_[0] &= ~0x00000010u; } -inline bool MethodDescriptorProto::_internal_client_streaming() const { - return _impl_.client_streaming_; -} inline bool MethodDescriptorProto::client_streaming() const { // @@protoc_insertion_point(field_get:google.protobuf.MethodDescriptorProto.client_streaming) return _internal_client_streaming(); } -inline void MethodDescriptorProto::_internal_set_client_streaming(bool value) { - _impl_._has_bits_[0] |= 0x00000010u; - _impl_.client_streaming_ = value; -} inline void MethodDescriptorProto::set_client_streaming(bool value) { + ; _internal_set_client_streaming(value); // @@protoc_insertion_point(field_set:google.protobuf.MethodDescriptorProto.client_streaming) } +inline bool MethodDescriptorProto::_internal_client_streaming() const { + return _impl_.client_streaming_; +} +inline void MethodDescriptorProto::_internal_set_client_streaming(bool value) { + _impl_._has_bits_[0] |= 0x00000010u; + _impl_.client_streaming_ = value; +} // optional bool server_streaming = 6 [default = false]; inline bool MethodDescriptorProto::has_server_streaming() const { @@ -11181,21 +11260,22 @@ inline void MethodDescriptorProto::clear_server_streaming() { _impl_.server_streaming_ = false; _impl_._has_bits_[0] &= ~0x00000020u; } -inline bool MethodDescriptorProto::_internal_server_streaming() const { - return _impl_.server_streaming_; -} inline bool MethodDescriptorProto::server_streaming() const { // @@protoc_insertion_point(field_get:google.protobuf.MethodDescriptorProto.server_streaming) return _internal_server_streaming(); } -inline void MethodDescriptorProto::_internal_set_server_streaming(bool value) { - _impl_._has_bits_[0] |= 0x00000020u; - _impl_.server_streaming_ = value; -} inline void MethodDescriptorProto::set_server_streaming(bool value) { + ; _internal_set_server_streaming(value); // @@protoc_insertion_point(field_set:google.protobuf.MethodDescriptorProto.server_streaming) } +inline bool MethodDescriptorProto::_internal_server_streaming() const { + return _impl_.server_streaming_; +} +inline void MethodDescriptorProto::_internal_set_server_streaming(bool value) { + _impl_._has_bits_[0] |= 0x00000020u; + _impl_.server_streaming_ = value; +} // ------------------------------------------------------------------- @@ -11336,21 +11416,22 @@ inline void FileOptions::clear_java_multiple_files() { _impl_.java_multiple_files_ = false; _impl_._has_bits_[0] &= ~0x00000400u; } -inline bool FileOptions::_internal_java_multiple_files() const { - return _impl_.java_multiple_files_; -} inline bool FileOptions::java_multiple_files() const { // @@protoc_insertion_point(field_get:google.protobuf.FileOptions.java_multiple_files) return _internal_java_multiple_files(); } -inline void FileOptions::_internal_set_java_multiple_files(bool value) { - _impl_._has_bits_[0] |= 0x00000400u; - _impl_.java_multiple_files_ = value; -} inline void FileOptions::set_java_multiple_files(bool value) { + ; _internal_set_java_multiple_files(value); // @@protoc_insertion_point(field_set:google.protobuf.FileOptions.java_multiple_files) } +inline bool FileOptions::_internal_java_multiple_files() const { + return _impl_.java_multiple_files_; +} +inline void FileOptions::_internal_set_java_multiple_files(bool value) { + _impl_._has_bits_[0] |= 0x00000400u; + _impl_.java_multiple_files_ = value; +} // optional bool java_generate_equals_and_hash = 20 [deprecated = true]; inline bool FileOptions::has_java_generate_equals_and_hash() const { @@ -11361,21 +11442,22 @@ inline void FileOptions::clear_java_generate_equals_and_hash() { _impl_.java_generate_equals_and_hash_ = false; _impl_._has_bits_[0] &= ~0x00000800u; } -inline bool FileOptions::_internal_java_generate_equals_and_hash() const { - return _impl_.java_generate_equals_and_hash_; -} inline bool FileOptions::java_generate_equals_and_hash() const { // @@protoc_insertion_point(field_get:google.protobuf.FileOptions.java_generate_equals_and_hash) return _internal_java_generate_equals_and_hash(); } -inline void FileOptions::_internal_set_java_generate_equals_and_hash(bool value) { - _impl_._has_bits_[0] |= 0x00000800u; - _impl_.java_generate_equals_and_hash_ = value; -} inline void FileOptions::set_java_generate_equals_and_hash(bool value) { + ; _internal_set_java_generate_equals_and_hash(value); // @@protoc_insertion_point(field_set:google.protobuf.FileOptions.java_generate_equals_and_hash) } +inline bool FileOptions::_internal_java_generate_equals_and_hash() const { + return _impl_.java_generate_equals_and_hash_; +} +inline void FileOptions::_internal_set_java_generate_equals_and_hash(bool value) { + _impl_._has_bits_[0] |= 0x00000800u; + _impl_.java_generate_equals_and_hash_ = value; +} // optional bool java_string_check_utf8 = 27 [default = false]; inline bool FileOptions::has_java_string_check_utf8() const { @@ -11386,21 +11468,22 @@ inline void FileOptions::clear_java_string_check_utf8() { _impl_.java_string_check_utf8_ = false; _impl_._has_bits_[0] &= ~0x00001000u; } -inline bool FileOptions::_internal_java_string_check_utf8() const { - return _impl_.java_string_check_utf8_; -} inline bool FileOptions::java_string_check_utf8() const { // @@protoc_insertion_point(field_get:google.protobuf.FileOptions.java_string_check_utf8) return _internal_java_string_check_utf8(); } -inline void FileOptions::_internal_set_java_string_check_utf8(bool value) { - _impl_._has_bits_[0] |= 0x00001000u; - _impl_.java_string_check_utf8_ = value; -} inline void FileOptions::set_java_string_check_utf8(bool value) { + ; _internal_set_java_string_check_utf8(value); // @@protoc_insertion_point(field_set:google.protobuf.FileOptions.java_string_check_utf8) } +inline bool FileOptions::_internal_java_string_check_utf8() const { + return _impl_.java_string_check_utf8_; +} +inline void FileOptions::_internal_set_java_string_check_utf8(bool value) { + _impl_._has_bits_[0] |= 0x00001000u; + _impl_.java_string_check_utf8_ = value; +} // optional .google.protobuf.FileOptions.OptimizeMode optimize_for = 9 [default = SPEED]; inline bool FileOptions::has_optimize_for() const { @@ -11500,21 +11583,22 @@ inline void FileOptions::clear_cc_generic_services() { _impl_.cc_generic_services_ = false; _impl_._has_bits_[0] &= ~0x00002000u; } -inline bool FileOptions::_internal_cc_generic_services() const { - return _impl_.cc_generic_services_; -} inline bool FileOptions::cc_generic_services() const { // @@protoc_insertion_point(field_get:google.protobuf.FileOptions.cc_generic_services) return _internal_cc_generic_services(); } -inline void FileOptions::_internal_set_cc_generic_services(bool value) { - _impl_._has_bits_[0] |= 0x00002000u; - _impl_.cc_generic_services_ = value; -} inline void FileOptions::set_cc_generic_services(bool value) { + ; _internal_set_cc_generic_services(value); // @@protoc_insertion_point(field_set:google.protobuf.FileOptions.cc_generic_services) } +inline bool FileOptions::_internal_cc_generic_services() const { + return _impl_.cc_generic_services_; +} +inline void FileOptions::_internal_set_cc_generic_services(bool value) { + _impl_._has_bits_[0] |= 0x00002000u; + _impl_.cc_generic_services_ = value; +} // optional bool java_generic_services = 17 [default = false]; inline bool FileOptions::has_java_generic_services() const { @@ -11525,21 +11609,22 @@ inline void FileOptions::clear_java_generic_services() { _impl_.java_generic_services_ = false; _impl_._has_bits_[0] &= ~0x00004000u; } -inline bool FileOptions::_internal_java_generic_services() const { - return _impl_.java_generic_services_; -} inline bool FileOptions::java_generic_services() const { // @@protoc_insertion_point(field_get:google.protobuf.FileOptions.java_generic_services) return _internal_java_generic_services(); } -inline void FileOptions::_internal_set_java_generic_services(bool value) { - _impl_._has_bits_[0] |= 0x00004000u; - _impl_.java_generic_services_ = value; -} inline void FileOptions::set_java_generic_services(bool value) { + ; _internal_set_java_generic_services(value); // @@protoc_insertion_point(field_set:google.protobuf.FileOptions.java_generic_services) } +inline bool FileOptions::_internal_java_generic_services() const { + return _impl_.java_generic_services_; +} +inline void FileOptions::_internal_set_java_generic_services(bool value) { + _impl_._has_bits_[0] |= 0x00004000u; + _impl_.java_generic_services_ = value; +} // optional bool py_generic_services = 18 [default = false]; inline bool FileOptions::has_py_generic_services() const { @@ -11550,21 +11635,22 @@ inline void FileOptions::clear_py_generic_services() { _impl_.py_generic_services_ = false; _impl_._has_bits_[0] &= ~0x00008000u; } -inline bool FileOptions::_internal_py_generic_services() const { - return _impl_.py_generic_services_; -} inline bool FileOptions::py_generic_services() const { // @@protoc_insertion_point(field_get:google.protobuf.FileOptions.py_generic_services) return _internal_py_generic_services(); } -inline void FileOptions::_internal_set_py_generic_services(bool value) { - _impl_._has_bits_[0] |= 0x00008000u; - _impl_.py_generic_services_ = value; -} inline void FileOptions::set_py_generic_services(bool value) { + ; _internal_set_py_generic_services(value); // @@protoc_insertion_point(field_set:google.protobuf.FileOptions.py_generic_services) } +inline bool FileOptions::_internal_py_generic_services() const { + return _impl_.py_generic_services_; +} +inline void FileOptions::_internal_set_py_generic_services(bool value) { + _impl_._has_bits_[0] |= 0x00008000u; + _impl_.py_generic_services_ = value; +} // optional bool php_generic_services = 42 [default = false]; inline bool FileOptions::has_php_generic_services() const { @@ -11575,21 +11661,22 @@ inline void FileOptions::clear_php_generic_services() { _impl_.php_generic_services_ = false; _impl_._has_bits_[0] &= ~0x00010000u; } -inline bool FileOptions::_internal_php_generic_services() const { - return _impl_.php_generic_services_; -} inline bool FileOptions::php_generic_services() const { // @@protoc_insertion_point(field_get:google.protobuf.FileOptions.php_generic_services) return _internal_php_generic_services(); } -inline void FileOptions::_internal_set_php_generic_services(bool value) { - _impl_._has_bits_[0] |= 0x00010000u; - _impl_.php_generic_services_ = value; -} inline void FileOptions::set_php_generic_services(bool value) { + ; _internal_set_php_generic_services(value); // @@protoc_insertion_point(field_set:google.protobuf.FileOptions.php_generic_services) } +inline bool FileOptions::_internal_php_generic_services() const { + return _impl_.php_generic_services_; +} +inline void FileOptions::_internal_set_php_generic_services(bool value) { + _impl_._has_bits_[0] |= 0x00010000u; + _impl_.php_generic_services_ = value; +} // optional bool deprecated = 23 [default = false]; inline bool FileOptions::has_deprecated() const { @@ -11600,21 +11687,22 @@ inline void FileOptions::clear_deprecated() { _impl_.deprecated_ = false; _impl_._has_bits_[0] &= ~0x00020000u; } -inline bool FileOptions::_internal_deprecated() const { - return _impl_.deprecated_; -} inline bool FileOptions::deprecated() const { // @@protoc_insertion_point(field_get:google.protobuf.FileOptions.deprecated) return _internal_deprecated(); } -inline void FileOptions::_internal_set_deprecated(bool value) { - _impl_._has_bits_[0] |= 0x00020000u; - _impl_.deprecated_ = value; -} inline void FileOptions::set_deprecated(bool value) { + ; _internal_set_deprecated(value); // @@protoc_insertion_point(field_set:google.protobuf.FileOptions.deprecated) } +inline bool FileOptions::_internal_deprecated() const { + return _impl_.deprecated_; +} +inline void FileOptions::_internal_set_deprecated(bool value) { + _impl_._has_bits_[0] |= 0x00020000u; + _impl_.deprecated_ = value; +} // optional bool cc_enable_arenas = 31 [default = true]; inline bool FileOptions::has_cc_enable_arenas() const { @@ -11625,21 +11713,22 @@ inline void FileOptions::clear_cc_enable_arenas() { _impl_.cc_enable_arenas_ = true; _impl_._has_bits_[0] &= ~0x00080000u; } -inline bool FileOptions::_internal_cc_enable_arenas() const { - return _impl_.cc_enable_arenas_; -} inline bool FileOptions::cc_enable_arenas() const { // @@protoc_insertion_point(field_get:google.protobuf.FileOptions.cc_enable_arenas) return _internal_cc_enable_arenas(); } -inline void FileOptions::_internal_set_cc_enable_arenas(bool value) { - _impl_._has_bits_[0] |= 0x00080000u; - _impl_.cc_enable_arenas_ = value; -} inline void FileOptions::set_cc_enable_arenas(bool value) { + ; _internal_set_cc_enable_arenas(value); // @@protoc_insertion_point(field_set:google.protobuf.FileOptions.cc_enable_arenas) } +inline bool FileOptions::_internal_cc_enable_arenas() const { + return _impl_.cc_enable_arenas_; +} +inline void FileOptions::_internal_set_cc_enable_arenas(bool value) { + _impl_._has_bits_[0] |= 0x00080000u; + _impl_.cc_enable_arenas_ = value; +} // optional string objc_class_prefix = 36; inline bool FileOptions::has_objc_class_prefix() const { @@ -12135,21 +12224,22 @@ inline void MessageOptions::clear_message_set_wire_format() { _impl_.message_set_wire_format_ = false; _impl_._has_bits_[0] &= ~0x00000001u; } -inline bool MessageOptions::_internal_message_set_wire_format() const { - return _impl_.message_set_wire_format_; -} inline bool MessageOptions::message_set_wire_format() const { // @@protoc_insertion_point(field_get:google.protobuf.MessageOptions.message_set_wire_format) return _internal_message_set_wire_format(); } -inline void MessageOptions::_internal_set_message_set_wire_format(bool value) { - _impl_._has_bits_[0] |= 0x00000001u; - _impl_.message_set_wire_format_ = value; -} inline void MessageOptions::set_message_set_wire_format(bool value) { + ; _internal_set_message_set_wire_format(value); // @@protoc_insertion_point(field_set:google.protobuf.MessageOptions.message_set_wire_format) } +inline bool MessageOptions::_internal_message_set_wire_format() const { + return _impl_.message_set_wire_format_; +} +inline void MessageOptions::_internal_set_message_set_wire_format(bool value) { + _impl_._has_bits_[0] |= 0x00000001u; + _impl_.message_set_wire_format_ = value; +} // optional bool no_standard_descriptor_accessor = 2 [default = false]; inline bool MessageOptions::has_no_standard_descriptor_accessor() const { @@ -12160,21 +12250,22 @@ inline void MessageOptions::clear_no_standard_descriptor_accessor() { _impl_.no_standard_descriptor_accessor_ = false; _impl_._has_bits_[0] &= ~0x00000002u; } -inline bool MessageOptions::_internal_no_standard_descriptor_accessor() const { - return _impl_.no_standard_descriptor_accessor_; -} inline bool MessageOptions::no_standard_descriptor_accessor() const { // @@protoc_insertion_point(field_get:google.protobuf.MessageOptions.no_standard_descriptor_accessor) return _internal_no_standard_descriptor_accessor(); } -inline void MessageOptions::_internal_set_no_standard_descriptor_accessor(bool value) { - _impl_._has_bits_[0] |= 0x00000002u; - _impl_.no_standard_descriptor_accessor_ = value; -} inline void MessageOptions::set_no_standard_descriptor_accessor(bool value) { + ; _internal_set_no_standard_descriptor_accessor(value); // @@protoc_insertion_point(field_set:google.protobuf.MessageOptions.no_standard_descriptor_accessor) } +inline bool MessageOptions::_internal_no_standard_descriptor_accessor() const { + return _impl_.no_standard_descriptor_accessor_; +} +inline void MessageOptions::_internal_set_no_standard_descriptor_accessor(bool value) { + _impl_._has_bits_[0] |= 0x00000002u; + _impl_.no_standard_descriptor_accessor_ = value; +} // optional bool deprecated = 3 [default = false]; inline bool MessageOptions::has_deprecated() const { @@ -12185,21 +12276,22 @@ inline void MessageOptions::clear_deprecated() { _impl_.deprecated_ = false; _impl_._has_bits_[0] &= ~0x00000004u; } -inline bool MessageOptions::_internal_deprecated() const { - return _impl_.deprecated_; -} inline bool MessageOptions::deprecated() const { // @@protoc_insertion_point(field_get:google.protobuf.MessageOptions.deprecated) return _internal_deprecated(); } -inline void MessageOptions::_internal_set_deprecated(bool value) { - _impl_._has_bits_[0] |= 0x00000004u; - _impl_.deprecated_ = value; -} inline void MessageOptions::set_deprecated(bool value) { + ; _internal_set_deprecated(value); // @@protoc_insertion_point(field_set:google.protobuf.MessageOptions.deprecated) } +inline bool MessageOptions::_internal_deprecated() const { + return _impl_.deprecated_; +} +inline void MessageOptions::_internal_set_deprecated(bool value) { + _impl_._has_bits_[0] |= 0x00000004u; + _impl_.deprecated_ = value; +} // optional bool map_entry = 7; inline bool MessageOptions::has_map_entry() const { @@ -12210,21 +12302,22 @@ inline void MessageOptions::clear_map_entry() { _impl_.map_entry_ = false; _impl_._has_bits_[0] &= ~0x00000008u; } -inline bool MessageOptions::_internal_map_entry() const { - return _impl_.map_entry_; -} inline bool MessageOptions::map_entry() const { // @@protoc_insertion_point(field_get:google.protobuf.MessageOptions.map_entry) return _internal_map_entry(); } -inline void MessageOptions::_internal_set_map_entry(bool value) { - _impl_._has_bits_[0] |= 0x00000008u; - _impl_.map_entry_ = value; -} inline void MessageOptions::set_map_entry(bool value) { + ; _internal_set_map_entry(value); // @@protoc_insertion_point(field_set:google.protobuf.MessageOptions.map_entry) } +inline bool MessageOptions::_internal_map_entry() const { + return _impl_.map_entry_; +} +inline void MessageOptions::_internal_set_map_entry(bool value) { + _impl_._has_bits_[0] |= 0x00000008u; + _impl_.map_entry_ = value; +} // optional bool deprecated_legacy_json_field_conflicts = 11 [deprecated = true]; inline bool MessageOptions::has_deprecated_legacy_json_field_conflicts() const { @@ -12235,21 +12328,22 @@ inline void MessageOptions::clear_deprecated_legacy_json_field_conflicts() { _impl_.deprecated_legacy_json_field_conflicts_ = false; _impl_._has_bits_[0] &= ~0x00000010u; } -inline bool MessageOptions::_internal_deprecated_legacy_json_field_conflicts() const { - return _impl_.deprecated_legacy_json_field_conflicts_; -} inline bool MessageOptions::deprecated_legacy_json_field_conflicts() const { // @@protoc_insertion_point(field_get:google.protobuf.MessageOptions.deprecated_legacy_json_field_conflicts) return _internal_deprecated_legacy_json_field_conflicts(); } -inline void MessageOptions::_internal_set_deprecated_legacy_json_field_conflicts(bool value) { - _impl_._has_bits_[0] |= 0x00000010u; - _impl_.deprecated_legacy_json_field_conflicts_ = value; -} inline void MessageOptions::set_deprecated_legacy_json_field_conflicts(bool value) { + ; _internal_set_deprecated_legacy_json_field_conflicts(value); // @@protoc_insertion_point(field_set:google.protobuf.MessageOptions.deprecated_legacy_json_field_conflicts) } +inline bool MessageOptions::_internal_deprecated_legacy_json_field_conflicts() const { + return _impl_.deprecated_legacy_json_field_conflicts_; +} +inline void MessageOptions::_internal_set_deprecated_legacy_json_field_conflicts(bool value) { + _impl_._has_bits_[0] |= 0x00000010u; + _impl_.deprecated_legacy_json_field_conflicts_ = value; +} // repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999; inline int MessageOptions::_internal_uninterpreted_option_size() const { @@ -12330,21 +12424,22 @@ inline void FieldOptions::clear_packed() { _impl_.packed_ = false; _impl_._has_bits_[0] &= ~0x00000004u; } -inline bool FieldOptions::_internal_packed() const { - return _impl_.packed_; -} inline bool FieldOptions::packed() const { // @@protoc_insertion_point(field_get:google.protobuf.FieldOptions.packed) return _internal_packed(); } -inline void FieldOptions::_internal_set_packed(bool value) { - _impl_._has_bits_[0] |= 0x00000004u; - _impl_.packed_ = value; -} inline void FieldOptions::set_packed(bool value) { + ; _internal_set_packed(value); // @@protoc_insertion_point(field_set:google.protobuf.FieldOptions.packed) } +inline bool FieldOptions::_internal_packed() const { + return _impl_.packed_; +} +inline void FieldOptions::_internal_set_packed(bool value) { + _impl_._has_bits_[0] |= 0x00000004u; + _impl_.packed_ = value; +} // optional .google.protobuf.FieldOptions.JSType jstype = 6 [default = JS_NORMAL]; inline bool FieldOptions::has_jstype() const { @@ -12381,21 +12476,22 @@ inline void FieldOptions::clear_lazy() { _impl_.lazy_ = false; _impl_._has_bits_[0] &= ~0x00000008u; } -inline bool FieldOptions::_internal_lazy() const { - return _impl_.lazy_; -} inline bool FieldOptions::lazy() const { // @@protoc_insertion_point(field_get:google.protobuf.FieldOptions.lazy) return _internal_lazy(); } -inline void FieldOptions::_internal_set_lazy(bool value) { - _impl_._has_bits_[0] |= 0x00000008u; - _impl_.lazy_ = value; -} inline void FieldOptions::set_lazy(bool value) { + ; _internal_set_lazy(value); // @@protoc_insertion_point(field_set:google.protobuf.FieldOptions.lazy) } +inline bool FieldOptions::_internal_lazy() const { + return _impl_.lazy_; +} +inline void FieldOptions::_internal_set_lazy(bool value) { + _impl_._has_bits_[0] |= 0x00000008u; + _impl_.lazy_ = value; +} // optional bool unverified_lazy = 15 [default = false]; inline bool FieldOptions::has_unverified_lazy() const { @@ -12406,21 +12502,22 @@ inline void FieldOptions::clear_unverified_lazy() { _impl_.unverified_lazy_ = false; _impl_._has_bits_[0] &= ~0x00000010u; } -inline bool FieldOptions::_internal_unverified_lazy() const { - return _impl_.unverified_lazy_; -} inline bool FieldOptions::unverified_lazy() const { // @@protoc_insertion_point(field_get:google.protobuf.FieldOptions.unverified_lazy) return _internal_unverified_lazy(); } -inline void FieldOptions::_internal_set_unverified_lazy(bool value) { - _impl_._has_bits_[0] |= 0x00000010u; - _impl_.unverified_lazy_ = value; -} inline void FieldOptions::set_unverified_lazy(bool value) { + ; _internal_set_unverified_lazy(value); // @@protoc_insertion_point(field_set:google.protobuf.FieldOptions.unverified_lazy) } +inline bool FieldOptions::_internal_unverified_lazy() const { + return _impl_.unverified_lazy_; +} +inline void FieldOptions::_internal_set_unverified_lazy(bool value) { + _impl_._has_bits_[0] |= 0x00000010u; + _impl_.unverified_lazy_ = value; +} // optional bool deprecated = 3 [default = false]; inline bool FieldOptions::has_deprecated() const { @@ -12431,21 +12528,22 @@ inline void FieldOptions::clear_deprecated() { _impl_.deprecated_ = false; _impl_._has_bits_[0] &= ~0x00000020u; } -inline bool FieldOptions::_internal_deprecated() const { - return _impl_.deprecated_; -} inline bool FieldOptions::deprecated() const { // @@protoc_insertion_point(field_get:google.protobuf.FieldOptions.deprecated) return _internal_deprecated(); } -inline void FieldOptions::_internal_set_deprecated(bool value) { - _impl_._has_bits_[0] |= 0x00000020u; - _impl_.deprecated_ = value; -} inline void FieldOptions::set_deprecated(bool value) { + ; _internal_set_deprecated(value); // @@protoc_insertion_point(field_set:google.protobuf.FieldOptions.deprecated) } +inline bool FieldOptions::_internal_deprecated() const { + return _impl_.deprecated_; +} +inline void FieldOptions::_internal_set_deprecated(bool value) { + _impl_._has_bits_[0] |= 0x00000020u; + _impl_.deprecated_ = value; +} // optional bool weak = 10 [default = false]; inline bool FieldOptions::has_weak() const { @@ -12456,21 +12554,22 @@ inline void FieldOptions::clear_weak() { _impl_.weak_ = false; _impl_._has_bits_[0] &= ~0x00000040u; } -inline bool FieldOptions::_internal_weak() const { - return _impl_.weak_; -} inline bool FieldOptions::weak() const { // @@protoc_insertion_point(field_get:google.protobuf.FieldOptions.weak) return _internal_weak(); } -inline void FieldOptions::_internal_set_weak(bool value) { - _impl_._has_bits_[0] |= 0x00000040u; - _impl_.weak_ = value; -} inline void FieldOptions::set_weak(bool value) { + ; _internal_set_weak(value); // @@protoc_insertion_point(field_set:google.protobuf.FieldOptions.weak) } +inline bool FieldOptions::_internal_weak() const { + return _impl_.weak_; +} +inline void FieldOptions::_internal_set_weak(bool value) { + _impl_._has_bits_[0] |= 0x00000040u; + _impl_.weak_ = value; +} // optional bool debug_redact = 16 [default = false]; inline bool FieldOptions::has_debug_redact() const { @@ -12481,21 +12580,22 @@ inline void FieldOptions::clear_debug_redact() { _impl_.debug_redact_ = false; _impl_._has_bits_[0] &= ~0x00000080u; } -inline bool FieldOptions::_internal_debug_redact() const { - return _impl_.debug_redact_; -} inline bool FieldOptions::debug_redact() const { // @@protoc_insertion_point(field_get:google.protobuf.FieldOptions.debug_redact) return _internal_debug_redact(); } -inline void FieldOptions::_internal_set_debug_redact(bool value) { - _impl_._has_bits_[0] |= 0x00000080u; - _impl_.debug_redact_ = value; -} inline void FieldOptions::set_debug_redact(bool value) { + ; _internal_set_debug_redact(value); // @@protoc_insertion_point(field_set:google.protobuf.FieldOptions.debug_redact) } +inline bool FieldOptions::_internal_debug_redact() const { + return _impl_.debug_redact_; +} +inline void FieldOptions::_internal_set_debug_redact(bool value) { + _impl_._has_bits_[0] |= 0x00000080u; + _impl_.debug_redact_ = value; +} // repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999; inline int FieldOptions::_internal_uninterpreted_option_size() const { @@ -12594,21 +12694,22 @@ inline void EnumOptions::clear_allow_alias() { _impl_.allow_alias_ = false; _impl_._has_bits_[0] &= ~0x00000001u; } -inline bool EnumOptions::_internal_allow_alias() const { - return _impl_.allow_alias_; -} inline bool EnumOptions::allow_alias() const { // @@protoc_insertion_point(field_get:google.protobuf.EnumOptions.allow_alias) return _internal_allow_alias(); } -inline void EnumOptions::_internal_set_allow_alias(bool value) { - _impl_._has_bits_[0] |= 0x00000001u; - _impl_.allow_alias_ = value; -} inline void EnumOptions::set_allow_alias(bool value) { + ; _internal_set_allow_alias(value); // @@protoc_insertion_point(field_set:google.protobuf.EnumOptions.allow_alias) } +inline bool EnumOptions::_internal_allow_alias() const { + return _impl_.allow_alias_; +} +inline void EnumOptions::_internal_set_allow_alias(bool value) { + _impl_._has_bits_[0] |= 0x00000001u; + _impl_.allow_alias_ = value; +} // optional bool deprecated = 3 [default = false]; inline bool EnumOptions::has_deprecated() const { @@ -12619,21 +12720,22 @@ inline void EnumOptions::clear_deprecated() { _impl_.deprecated_ = false; _impl_._has_bits_[0] &= ~0x00000002u; } -inline bool EnumOptions::_internal_deprecated() const { - return _impl_.deprecated_; -} inline bool EnumOptions::deprecated() const { // @@protoc_insertion_point(field_get:google.protobuf.EnumOptions.deprecated) return _internal_deprecated(); } -inline void EnumOptions::_internal_set_deprecated(bool value) { - _impl_._has_bits_[0] |= 0x00000002u; - _impl_.deprecated_ = value; -} inline void EnumOptions::set_deprecated(bool value) { + ; _internal_set_deprecated(value); // @@protoc_insertion_point(field_set:google.protobuf.EnumOptions.deprecated) } +inline bool EnumOptions::_internal_deprecated() const { + return _impl_.deprecated_; +} +inline void EnumOptions::_internal_set_deprecated(bool value) { + _impl_._has_bits_[0] |= 0x00000002u; + _impl_.deprecated_ = value; +} // optional bool deprecated_legacy_json_field_conflicts = 6 [deprecated = true]; inline bool EnumOptions::has_deprecated_legacy_json_field_conflicts() const { @@ -12644,21 +12746,22 @@ inline void EnumOptions::clear_deprecated_legacy_json_field_conflicts() { _impl_.deprecated_legacy_json_field_conflicts_ = false; _impl_._has_bits_[0] &= ~0x00000004u; } -inline bool EnumOptions::_internal_deprecated_legacy_json_field_conflicts() const { - return _impl_.deprecated_legacy_json_field_conflicts_; -} inline bool EnumOptions::deprecated_legacy_json_field_conflicts() const { // @@protoc_insertion_point(field_get:google.protobuf.EnumOptions.deprecated_legacy_json_field_conflicts) return _internal_deprecated_legacy_json_field_conflicts(); } -inline void EnumOptions::_internal_set_deprecated_legacy_json_field_conflicts(bool value) { - _impl_._has_bits_[0] |= 0x00000004u; - _impl_.deprecated_legacy_json_field_conflicts_ = value; -} inline void EnumOptions::set_deprecated_legacy_json_field_conflicts(bool value) { + ; _internal_set_deprecated_legacy_json_field_conflicts(value); // @@protoc_insertion_point(field_set:google.protobuf.EnumOptions.deprecated_legacy_json_field_conflicts) } +inline bool EnumOptions::_internal_deprecated_legacy_json_field_conflicts() const { + return _impl_.deprecated_legacy_json_field_conflicts_; +} +inline void EnumOptions::_internal_set_deprecated_legacy_json_field_conflicts(bool value) { + _impl_._has_bits_[0] |= 0x00000004u; + _impl_.deprecated_legacy_json_field_conflicts_ = value; +} // repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999; inline int EnumOptions::_internal_uninterpreted_option_size() const { @@ -12713,21 +12816,22 @@ inline void EnumValueOptions::clear_deprecated() { _impl_.deprecated_ = false; _impl_._has_bits_[0] &= ~0x00000001u; } -inline bool EnumValueOptions::_internal_deprecated() const { - return _impl_.deprecated_; -} inline bool EnumValueOptions::deprecated() const { // @@protoc_insertion_point(field_get:google.protobuf.EnumValueOptions.deprecated) return _internal_deprecated(); } -inline void EnumValueOptions::_internal_set_deprecated(bool value) { - _impl_._has_bits_[0] |= 0x00000001u; - _impl_.deprecated_ = value; -} inline void EnumValueOptions::set_deprecated(bool value) { + ; _internal_set_deprecated(value); // @@protoc_insertion_point(field_set:google.protobuf.EnumValueOptions.deprecated) } +inline bool EnumValueOptions::_internal_deprecated() const { + return _impl_.deprecated_; +} +inline void EnumValueOptions::_internal_set_deprecated(bool value) { + _impl_._has_bits_[0] |= 0x00000001u; + _impl_.deprecated_ = value; +} // repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999; inline int EnumValueOptions::_internal_uninterpreted_option_size() const { @@ -12782,21 +12886,22 @@ inline void ServiceOptions::clear_deprecated() { _impl_.deprecated_ = false; _impl_._has_bits_[0] &= ~0x00000001u; } -inline bool ServiceOptions::_internal_deprecated() const { - return _impl_.deprecated_; -} inline bool ServiceOptions::deprecated() const { // @@protoc_insertion_point(field_get:google.protobuf.ServiceOptions.deprecated) return _internal_deprecated(); } -inline void ServiceOptions::_internal_set_deprecated(bool value) { - _impl_._has_bits_[0] |= 0x00000001u; - _impl_.deprecated_ = value; -} inline void ServiceOptions::set_deprecated(bool value) { + ; _internal_set_deprecated(value); // @@protoc_insertion_point(field_set:google.protobuf.ServiceOptions.deprecated) } +inline bool ServiceOptions::_internal_deprecated() const { + return _impl_.deprecated_; +} +inline void ServiceOptions::_internal_set_deprecated(bool value) { + _impl_._has_bits_[0] |= 0x00000001u; + _impl_.deprecated_ = value; +} // repeated .google.protobuf.UninterpretedOption uninterpreted_option = 999; inline int ServiceOptions::_internal_uninterpreted_option_size() const { @@ -12851,21 +12956,22 @@ inline void MethodOptions::clear_deprecated() { _impl_.deprecated_ = false; _impl_._has_bits_[0] &= ~0x00000001u; } -inline bool MethodOptions::_internal_deprecated() const { - return _impl_.deprecated_; -} inline bool MethodOptions::deprecated() const { // @@protoc_insertion_point(field_get:google.protobuf.MethodOptions.deprecated) return _internal_deprecated(); } -inline void MethodOptions::_internal_set_deprecated(bool value) { - _impl_._has_bits_[0] |= 0x00000001u; - _impl_.deprecated_ = value; -} inline void MethodOptions::set_deprecated(bool value) { + ; _internal_set_deprecated(value); // @@protoc_insertion_point(field_set:google.protobuf.MethodOptions.deprecated) } +inline bool MethodOptions::_internal_deprecated() const { + return _impl_.deprecated_; +} +inline void MethodOptions::_internal_set_deprecated(bool value) { + _impl_._has_bits_[0] |= 0x00000001u; + _impl_.deprecated_ = value; +} // optional .google.protobuf.MethodOptions.IdempotencyLevel idempotency_level = 34 [default = IDEMPOTENCY_UNKNOWN]; inline bool MethodOptions::has_idempotency_level() const { @@ -13009,21 +13115,22 @@ inline void UninterpretedOption_NamePart::clear_is_extension() { _impl_.is_extension_ = false; _impl_._has_bits_[0] &= ~0x00000002u; } -inline bool UninterpretedOption_NamePart::_internal_is_extension() const { - return _impl_.is_extension_; -} inline bool UninterpretedOption_NamePart::is_extension() const { // @@protoc_insertion_point(field_get:google.protobuf.UninterpretedOption.NamePart.is_extension) return _internal_is_extension(); } -inline void UninterpretedOption_NamePart::_internal_set_is_extension(bool value) { - _impl_._has_bits_[0] |= 0x00000002u; - _impl_.is_extension_ = value; -} inline void UninterpretedOption_NamePart::set_is_extension(bool value) { + ; _internal_set_is_extension(value); // @@protoc_insertion_point(field_set:google.protobuf.UninterpretedOption.NamePart.is_extension) } +inline bool UninterpretedOption_NamePart::_internal_is_extension() const { + return _impl_.is_extension_; +} +inline void UninterpretedOption_NamePart::_internal_set_is_extension(bool value) { + _impl_._has_bits_[0] |= 0x00000002u; + _impl_.is_extension_ = value; +} // ------------------------------------------------------------------- @@ -13141,21 +13248,22 @@ inline void UninterpretedOption::clear_positive_int_value() { _impl_.positive_int_value_ = ::uint64_t{0u}; _impl_._has_bits_[0] &= ~0x00000008u; } -inline ::uint64_t UninterpretedOption::_internal_positive_int_value() const { - return _impl_.positive_int_value_; -} inline ::uint64_t UninterpretedOption::positive_int_value() const { // @@protoc_insertion_point(field_get:google.protobuf.UninterpretedOption.positive_int_value) return _internal_positive_int_value(); } -inline void UninterpretedOption::_internal_set_positive_int_value(::uint64_t value) { - _impl_._has_bits_[0] |= 0x00000008u; - _impl_.positive_int_value_ = value; -} inline void UninterpretedOption::set_positive_int_value(::uint64_t value) { + ; _internal_set_positive_int_value(value); // @@protoc_insertion_point(field_set:google.protobuf.UninterpretedOption.positive_int_value) } +inline ::uint64_t UninterpretedOption::_internal_positive_int_value() const { + return _impl_.positive_int_value_; +} +inline void UninterpretedOption::_internal_set_positive_int_value(::uint64_t value) { + _impl_._has_bits_[0] |= 0x00000008u; + _impl_.positive_int_value_ = value; +} // optional int64 negative_int_value = 5; inline bool UninterpretedOption::has_negative_int_value() const { @@ -13166,21 +13274,22 @@ inline void UninterpretedOption::clear_negative_int_value() { _impl_.negative_int_value_ = ::int64_t{0}; _impl_._has_bits_[0] &= ~0x00000010u; } -inline ::int64_t UninterpretedOption::_internal_negative_int_value() const { - return _impl_.negative_int_value_; -} inline ::int64_t UninterpretedOption::negative_int_value() const { // @@protoc_insertion_point(field_get:google.protobuf.UninterpretedOption.negative_int_value) return _internal_negative_int_value(); } -inline void UninterpretedOption::_internal_set_negative_int_value(::int64_t value) { - _impl_._has_bits_[0] |= 0x00000010u; - _impl_.negative_int_value_ = value; -} inline void UninterpretedOption::set_negative_int_value(::int64_t value) { + ; _internal_set_negative_int_value(value); // @@protoc_insertion_point(field_set:google.protobuf.UninterpretedOption.negative_int_value) } +inline ::int64_t UninterpretedOption::_internal_negative_int_value() const { + return _impl_.negative_int_value_; +} +inline void UninterpretedOption::_internal_set_negative_int_value(::int64_t value) { + _impl_._has_bits_[0] |= 0x00000010u; + _impl_.negative_int_value_ = value; +} // optional double double_value = 6; inline bool UninterpretedOption::has_double_value() const { @@ -13191,21 +13300,22 @@ inline void UninterpretedOption::clear_double_value() { _impl_.double_value_ = 0; _impl_._has_bits_[0] &= ~0x00000020u; } -inline double UninterpretedOption::_internal_double_value() const { - return _impl_.double_value_; -} inline double UninterpretedOption::double_value() const { // @@protoc_insertion_point(field_get:google.protobuf.UninterpretedOption.double_value) return _internal_double_value(); } -inline void UninterpretedOption::_internal_set_double_value(double value) { - _impl_._has_bits_[0] |= 0x00000020u; - _impl_.double_value_ = value; -} inline void UninterpretedOption::set_double_value(double value) { + ; _internal_set_double_value(value); // @@protoc_insertion_point(field_set:google.protobuf.UninterpretedOption.double_value) } +inline double UninterpretedOption::_internal_double_value() const { + return _impl_.double_value_; +} +inline void UninterpretedOption::_internal_set_double_value(double value) { + _impl_._has_bits_[0] |= 0x00000020u; + _impl_.double_value_ = value; +} // optional bytes string_value = 7; inline bool UninterpretedOption::has_string_value() const { @@ -13347,9 +13457,6 @@ inline int SourceCodeInfo_Location::path_size() const { inline void SourceCodeInfo_Location::clear_path() { _impl_.path_.Clear(); } -inline ::int32_t SourceCodeInfo_Location::_internal_path(int index) const { - return _impl_.path_.Get(index); -} inline ::int32_t SourceCodeInfo_Location::path(int index) const { // @@protoc_insertion_point(field_get:google.protobuf.SourceCodeInfo.Location.path) return _internal_path(index); @@ -13358,32 +13465,30 @@ inline void SourceCodeInfo_Location::set_path(int index, ::int32_t value) { _impl_.path_.Set(index, value); // @@protoc_insertion_point(field_set:google.protobuf.SourceCodeInfo.Location.path) } -inline void SourceCodeInfo_Location::_internal_add_path(::int32_t value) { - _impl_.path_.Add(value); -} inline void SourceCodeInfo_Location::add_path(::int32_t value) { _internal_add_path(value); // @@protoc_insertion_point(field_add:google.protobuf.SourceCodeInfo.Location.path) } -inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >& -SourceCodeInfo_Location::_internal_path() const { - return _impl_.path_; -} -inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >& -SourceCodeInfo_Location::path() const { +inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>& SourceCodeInfo_Location::path() const { // @@protoc_insertion_point(field_list:google.protobuf.SourceCodeInfo.Location.path) return _internal_path(); } -inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >* -SourceCodeInfo_Location::_internal_mutable_path() { - return &_impl_.path_; -} -inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >* -SourceCodeInfo_Location::mutable_path() { +inline ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>* SourceCodeInfo_Location::mutable_path() { // @@protoc_insertion_point(field_mutable_list:google.protobuf.SourceCodeInfo.Location.path) return _internal_mutable_path(); } +inline ::int32_t SourceCodeInfo_Location::_internal_path(int index) const { + return _impl_.path_.Get(index); +} +inline void SourceCodeInfo_Location::_internal_add_path(::int32_t value) { _impl_.path_.Add(value); } +inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>& SourceCodeInfo_Location::_internal_path() const { + return _impl_.path_; +} +inline ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>* SourceCodeInfo_Location::_internal_mutable_path() { + return &_impl_.path_; +} + // repeated int32 span = 2 [packed = true]; inline int SourceCodeInfo_Location::_internal_span_size() const { return _impl_.span_.size(); @@ -13394,9 +13499,6 @@ inline int SourceCodeInfo_Location::span_size() const { inline void SourceCodeInfo_Location::clear_span() { _impl_.span_.Clear(); } -inline ::int32_t SourceCodeInfo_Location::_internal_span(int index) const { - return _impl_.span_.Get(index); -} inline ::int32_t SourceCodeInfo_Location::span(int index) const { // @@protoc_insertion_point(field_get:google.protobuf.SourceCodeInfo.Location.span) return _internal_span(index); @@ -13405,32 +13507,30 @@ inline void SourceCodeInfo_Location::set_span(int index, ::int32_t value) { _impl_.span_.Set(index, value); // @@protoc_insertion_point(field_set:google.protobuf.SourceCodeInfo.Location.span) } -inline void SourceCodeInfo_Location::_internal_add_span(::int32_t value) { - _impl_.span_.Add(value); -} inline void SourceCodeInfo_Location::add_span(::int32_t value) { _internal_add_span(value); // @@protoc_insertion_point(field_add:google.protobuf.SourceCodeInfo.Location.span) } -inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >& -SourceCodeInfo_Location::_internal_span() const { - return _impl_.span_; -} -inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >& -SourceCodeInfo_Location::span() const { +inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>& SourceCodeInfo_Location::span() const { // @@protoc_insertion_point(field_list:google.protobuf.SourceCodeInfo.Location.span) return _internal_span(); } -inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >* -SourceCodeInfo_Location::_internal_mutable_span() { - return &_impl_.span_; -} -inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >* -SourceCodeInfo_Location::mutable_span() { +inline ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>* SourceCodeInfo_Location::mutable_span() { // @@protoc_insertion_point(field_mutable_list:google.protobuf.SourceCodeInfo.Location.span) return _internal_mutable_span(); } +inline ::int32_t SourceCodeInfo_Location::_internal_span(int index) const { + return _impl_.span_.Get(index); +} +inline void SourceCodeInfo_Location::_internal_add_span(::int32_t value) { _impl_.span_.Add(value); } +inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>& SourceCodeInfo_Location::_internal_span() const { + return _impl_.span_; +} +inline ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>* SourceCodeInfo_Location::_internal_mutable_span() { + return &_impl_.span_; +} + // optional string leading_comments = 3; inline bool SourceCodeInfo_Location::has_leading_comments() const { bool value = (_impl_._has_bits_[0] & 0x00000001u) != 0; @@ -13696,9 +13796,6 @@ inline int GeneratedCodeInfo_Annotation::path_size() const { inline void GeneratedCodeInfo_Annotation::clear_path() { _impl_.path_.Clear(); } -inline ::int32_t GeneratedCodeInfo_Annotation::_internal_path(int index) const { - return _impl_.path_.Get(index); -} inline ::int32_t GeneratedCodeInfo_Annotation::path(int index) const { // @@protoc_insertion_point(field_get:google.protobuf.GeneratedCodeInfo.Annotation.path) return _internal_path(index); @@ -13707,32 +13804,30 @@ inline void GeneratedCodeInfo_Annotation::set_path(int index, ::int32_t value) { _impl_.path_.Set(index, value); // @@protoc_insertion_point(field_set:google.protobuf.GeneratedCodeInfo.Annotation.path) } -inline void GeneratedCodeInfo_Annotation::_internal_add_path(::int32_t value) { - _impl_.path_.Add(value); -} inline void GeneratedCodeInfo_Annotation::add_path(::int32_t value) { _internal_add_path(value); // @@protoc_insertion_point(field_add:google.protobuf.GeneratedCodeInfo.Annotation.path) } -inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >& -GeneratedCodeInfo_Annotation::_internal_path() const { - return _impl_.path_; -} -inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >& -GeneratedCodeInfo_Annotation::path() const { +inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>& GeneratedCodeInfo_Annotation::path() const { // @@protoc_insertion_point(field_list:google.protobuf.GeneratedCodeInfo.Annotation.path) return _internal_path(); } -inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >* -GeneratedCodeInfo_Annotation::_internal_mutable_path() { - return &_impl_.path_; -} -inline ::PROTOBUF_NAMESPACE_ID::RepeatedField< ::int32_t >* -GeneratedCodeInfo_Annotation::mutable_path() { +inline ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>* GeneratedCodeInfo_Annotation::mutable_path() { // @@protoc_insertion_point(field_mutable_list:google.protobuf.GeneratedCodeInfo.Annotation.path) return _internal_mutable_path(); } +inline ::int32_t GeneratedCodeInfo_Annotation::_internal_path(int index) const { + return _impl_.path_.Get(index); +} +inline void GeneratedCodeInfo_Annotation::_internal_add_path(::int32_t value) { _impl_.path_.Add(value); } +inline const ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>& GeneratedCodeInfo_Annotation::_internal_path() const { + return _impl_.path_; +} +inline ::PROTOBUF_NAMESPACE_ID::RepeatedField<::int32_t>* GeneratedCodeInfo_Annotation::_internal_mutable_path() { + return &_impl_.path_; +} + // optional string source_file = 2; inline bool GeneratedCodeInfo_Annotation::has_source_file() const { bool value = (_impl_._has_bits_[0] & 0x00000001u) != 0; @@ -13805,21 +13900,22 @@ inline void GeneratedCodeInfo_Annotation::clear_begin() { _impl_.begin_ = 0; _impl_._has_bits_[0] &= ~0x00000002u; } -inline ::int32_t GeneratedCodeInfo_Annotation::_internal_begin() const { - return _impl_.begin_; -} inline ::int32_t GeneratedCodeInfo_Annotation::begin() const { // @@protoc_insertion_point(field_get:google.protobuf.GeneratedCodeInfo.Annotation.begin) return _internal_begin(); } -inline void GeneratedCodeInfo_Annotation::_internal_set_begin(::int32_t value) { - _impl_._has_bits_[0] |= 0x00000002u; - _impl_.begin_ = value; -} inline void GeneratedCodeInfo_Annotation::set_begin(::int32_t value) { + ; _internal_set_begin(value); // @@protoc_insertion_point(field_set:google.protobuf.GeneratedCodeInfo.Annotation.begin) } +inline ::int32_t GeneratedCodeInfo_Annotation::_internal_begin() const { + return _impl_.begin_; +} +inline void GeneratedCodeInfo_Annotation::_internal_set_begin(::int32_t value) { + _impl_._has_bits_[0] |= 0x00000002u; + _impl_.begin_ = value; +} // optional int32 end = 4; inline bool GeneratedCodeInfo_Annotation::has_end() const { @@ -13830,21 +13926,22 @@ inline void GeneratedCodeInfo_Annotation::clear_end() { _impl_.end_ = 0; _impl_._has_bits_[0] &= ~0x00000004u; } -inline ::int32_t GeneratedCodeInfo_Annotation::_internal_end() const { - return _impl_.end_; -} inline ::int32_t GeneratedCodeInfo_Annotation::end() const { // @@protoc_insertion_point(field_get:google.protobuf.GeneratedCodeInfo.Annotation.end) return _internal_end(); } -inline void GeneratedCodeInfo_Annotation::_internal_set_end(::int32_t value) { - _impl_._has_bits_[0] |= 0x00000004u; - _impl_.end_ = value; -} inline void GeneratedCodeInfo_Annotation::set_end(::int32_t value) { + ; _internal_set_end(value); // @@protoc_insertion_point(field_set:google.protobuf.GeneratedCodeInfo.Annotation.end) } +inline ::int32_t GeneratedCodeInfo_Annotation::_internal_end() const { + return _impl_.end_; +} +inline void GeneratedCodeInfo_Annotation::_internal_set_end(::int32_t value) { + _impl_._has_bits_[0] |= 0x00000004u; + _impl_.end_ = value; +} // optional .google.protobuf.GeneratedCodeInfo.Annotation.Semantic semantic = 5; inline bool GeneratedCodeInfo_Annotation::has_semantic() const { diff --git a/src/google/protobuf/wire_format_lite.cc b/src/google/protobuf/wire_format_lite.cc index 2ed92101e0..14371fa579 100644 --- a/src/google/protobuf/wire_format_lite.cc +++ b/src/google/protobuf/wire_format_lite.cc @@ -64,6 +64,14 @@ const int WireFormatLite::kMessageSetMessageTag; #endif +constexpr size_t WireFormatLite::kFixed32Size; +constexpr size_t WireFormatLite::kFixed64Size; +constexpr size_t WireFormatLite::kSFixed32Size; +constexpr size_t WireFormatLite::kSFixed64Size; +constexpr size_t WireFormatLite::kFloatSize; +constexpr size_t WireFormatLite::kDoubleSize; +constexpr size_t WireFormatLite::kBoolSize; + // IBM xlC requires prefixing constants with WireFormatLite:: const size_t WireFormatLite::kMessageSetItemTagsSize = io::CodedOutputStream::StaticVarintSize32<