diff options
Diffstat (limited to 'src/google/protobuf/struct.pb.cc')
-rw-r--r-- | src/google/protobuf/struct.pb.cc | 207 |
1 files changed, 141 insertions, 66 deletions
diff --git a/src/google/protobuf/struct.pb.cc b/src/google/protobuf/struct.pb.cc index a7ce0040..02d9306e 100644 --- a/src/google/protobuf/struct.pb.cc +++ b/src/google/protobuf/struct.pb.cc @@ -19,12 +19,20 @@ namespace google { namespace protobuf { -class Struct_FieldsEntryDefaultTypeInternal : public ::google::protobuf::internal::ExplicitlyConstructed<Struct::Struct_FieldsEntry> { +class Struct_FieldsEntryDefaultTypeInternal { +public: + ::google::protobuf::internal::ExplicitlyConstructed<Struct::Struct_FieldsEntry> + _instance; } _Struct_FieldsEntry_default_instance_; -class StructDefaultTypeInternal : public ::google::protobuf::internal::ExplicitlyConstructed<Struct> { +class StructDefaultTypeInternal { +public: + ::google::protobuf::internal::ExplicitlyConstructed<Struct> + _instance; } _Struct_default_instance_; -class ValueDefaultTypeInternal : public ::google::protobuf::internal::ExplicitlyConstructed<Value> { - public: +class ValueDefaultTypeInternal { +public: + ::google::protobuf::internal::ExplicitlyConstructed<Value> + _instance; int null_value_; double number_value_; ::google::protobuf::internal::ArenaStringPtr string_value_; @@ -32,7 +40,10 @@ class ValueDefaultTypeInternal : public ::google::protobuf::internal::Explicitly const ::google::protobuf::Struct* struct_value_; const ::google::protobuf::ListValue* list_value_; } _Value_default_instance_; -class ListValueDefaultTypeInternal : public ::google::protobuf::internal::ExplicitlyConstructed<ListValue> { +class ListValueDefaultTypeInternal { +public: + ::google::protobuf::internal::ExplicitlyConstructed<ListValue> + _instance; } _ListValue_default_instance_; namespace protobuf_google_2fprotobuf_2fstruct_2eproto { @@ -46,23 +57,23 @@ const ::google::protobuf::EnumDescriptor* file_level_enum_descriptors[1]; } // namespace PROTOBUF_CONSTEXPR_VAR ::google::protobuf::internal::ParseTableField - const TableStruct::entries[] = { + const TableStruct::entries[] GOOGLE_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { {0, 0, 0, ::google::protobuf::internal::kInvalidMask, 0, 0}, }; PROTOBUF_CONSTEXPR_VAR ::google::protobuf::internal::AuxillaryParseTableField - const TableStruct::aux[] = { + const TableStruct::aux[] GOOGLE_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { ::google::protobuf::internal::AuxillaryParseTableField(), }; PROTOBUF_CONSTEXPR_VAR ::google::protobuf::internal::ParseTable const - TableStruct::schema[] = { - { NULL, NULL, 0, -1, -1, false }, - { NULL, NULL, 0, -1, -1, false }, - { NULL, NULL, 0, -1, -1, false }, - { NULL, NULL, 0, -1, -1, false }, + TableStruct::schema[] GOOGLE_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { + { NULL, NULL, 0, -1, -1, -1, -1, NULL, false }, + { NULL, NULL, 0, -1, -1, -1, -1, NULL, false }, + { NULL, NULL, 0, -1, -1, -1, -1, NULL, false }, + { NULL, NULL, 0, -1, -1, -1, -1, NULL, false }, }; -const ::google::protobuf::uint32 TableStruct::offsets[] = { +const ::google::protobuf::uint32 TableStruct::offsets[] GOOGLE_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { ~0u, // no _has_bits_ GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Struct, _internal_metadata_), ~0u, // no _extensions_ @@ -74,12 +85,12 @@ const ::google::protobuf::uint32 TableStruct::offsets[] = { ~0u, // no _extensions_ GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Value, _oneof_case_[0]), ~0u, // no _weak_field_map_ - GOOGLE_PROTOBUF_GENERATED_DEFAULT_ONEOF_FIELD_OFFSET((&_Value_default_instance_), null_value_), - GOOGLE_PROTOBUF_GENERATED_DEFAULT_ONEOF_FIELD_OFFSET((&_Value_default_instance_), number_value_), - GOOGLE_PROTOBUF_GENERATED_DEFAULT_ONEOF_FIELD_OFFSET((&_Value_default_instance_), string_value_), - GOOGLE_PROTOBUF_GENERATED_DEFAULT_ONEOF_FIELD_OFFSET((&_Value_default_instance_), bool_value_), - GOOGLE_PROTOBUF_GENERATED_DEFAULT_ONEOF_FIELD_OFFSET((&_Value_default_instance_), struct_value_), - GOOGLE_PROTOBUF_GENERATED_DEFAULT_ONEOF_FIELD_OFFSET((&_Value_default_instance_), list_value_), + offsetof(ValueDefaultTypeInternal, null_value_), + offsetof(ValueDefaultTypeInternal, number_value_), + offsetof(ValueDefaultTypeInternal, string_value_), + offsetof(ValueDefaultTypeInternal, bool_value_), + offsetof(ValueDefaultTypeInternal, struct_value_), + offsetof(ValueDefaultTypeInternal, list_value_), GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(Value, kind_), ~0u, // no _has_bits_ GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ListValue, _internal_metadata_), @@ -88,8 +99,7 @@ const ::google::protobuf::uint32 TableStruct::offsets[] = { ~0u, // no _weak_field_map_ GOOGLE_PROTOBUF_GENERATED_MESSAGE_FIELD_OFFSET(ListValue, values_), }; - -static const ::google::protobuf::internal::MigrationSchema schemas[] = { +static const ::google::protobuf::internal::MigrationSchema schemas[] GOOGLE_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { { 0, -1, sizeof(Struct)}, { 6, -1, sizeof(Value)}, { 18, -1, sizeof(ListValue)}, @@ -110,7 +120,7 @@ void protobuf_AssignDescriptors() { AssignDescriptors( "google/protobuf/struct.proto", schemas, file_default_instances, TableStruct::offsets, factory, file_level_metadata, file_level_enum_descriptors, NULL); -file_level_metadata[0].reflection = Struct::Struct_FieldsEntry::CreateReflection(file_level_metadata[0].descriptor, _Struct_FieldsEntry_default_instance_.get_mutable()); +file_level_metadata[0].reflection = Struct::Struct_FieldsEntry::CreateReflection(file_level_metadata[0].descriptor, _Struct_FieldsEntry_default_instance_._instance.get_mutable()); } void protobuf_AssignDescriptorsOnce() { @@ -125,27 +135,20 @@ void protobuf_RegisterTypes(const ::std::string&) { } } // namespace - -void TableStruct::Shutdown() { - _Struct_default_instance_.Shutdown(); - delete file_level_metadata[1].reflection; - _Value_default_instance_.Shutdown(); - delete file_level_metadata[2].reflection; - _ListValue_default_instance_.Shutdown(); - delete file_level_metadata[3].reflection; - delete file_level_metadata[0].reflection; -} - void TableStruct::InitDefaultsImpl() { GOOGLE_PROTOBUF_VERIFY_VERSION; ::google::protobuf::internal::InitProtobufDefaults(); - _Struct_FieldsEntry_default_instance_.DefaultConstruct(); - _Struct_default_instance_.DefaultConstruct(); - _Value_default_instance_.DefaultConstruct(); - _ListValue_default_instance_.DefaultConstruct(); - _Struct_FieldsEntry_default_instance_.get_mutable()->set_default_instance(_Struct_FieldsEntry_default_instance_.get_mutable()); - _Struct_FieldsEntry_default_instance_.get_mutable()->InitAsDefaultInstance(); + _Struct_FieldsEntry_default_instance_._instance.DefaultConstruct(); + ::google::protobuf::internal::OnShutdownDestroyMessage( + &_Struct_FieldsEntry_default_instance_);_Struct_default_instance_._instance.DefaultConstruct(); + ::google::protobuf::internal::OnShutdownDestroyMessage( + &_Struct_default_instance_);_Value_default_instance_._instance.DefaultConstruct(); + ::google::protobuf::internal::OnShutdownDestroyMessage( + &_Value_default_instance_);_ListValue_default_instance_._instance.DefaultConstruct(); + ::google::protobuf::internal::OnShutdownDestroyMessage( + &_ListValue_default_instance_);_Struct_FieldsEntry_default_instance_._instance.get_mutable()->set_default_instance(_Struct_FieldsEntry_default_instance_._instance.get_mutable()); + _Struct_FieldsEntry_default_instance_._instance.get_mutable()->InitAsDefaultInstance(); _Value_default_instance_.null_value_ = 0; _Value_default_instance_.number_value_ = 0; _Value_default_instance_.string_value_.UnsafeSetDefault( @@ -164,7 +167,7 @@ void InitDefaults() { namespace { void AddDescriptorsImpl() { InitDefaults(); - static const char descriptor[] = { + static const char descriptor[] GOOGLE_ATTRIBUTE_SECTION_VARIABLE(protodesc_cold) = { "\n\034google/protobuf/struct.proto\022\017google.p" "rotobuf\"\204\001\n\006Struct\0223\n\006fields\030\001 \003(\0132#.goo" "gle.protobuf.Struct.FieldsEntry\032E\n\013Field" @@ -187,7 +190,6 @@ void AddDescriptorsImpl() { descriptor, 641); ::google::protobuf::MessageFactory::InternalRegisterGeneratedFile( "google/protobuf/struct.proto", &protobuf_RegisterTypes); - ::google::protobuf::internal::OnShutdown(&TableStruct::Shutdown); } } // anonymous namespace @@ -280,6 +282,7 @@ Struct::~Struct() { void Struct::SharedDtor() { ::google::protobuf::Arena* arena = GetArenaNoVirtual(); + GOOGLE_DCHECK(arena == NULL); if (arena != NULL) { return; } @@ -313,7 +316,12 @@ Struct* Struct::New(::google::protobuf::Arena* arena) const { void Struct::Clear() { // @@protoc_insertion_point(message_clear_start:google.protobuf.Struct) + ::google::protobuf::uint32 cached_has_bits = 0; + // Prevent compiler warnings about cached_has_bits being unused + (void) cached_has_bits; + fields_.Clear(); + _internal_metadata_.Clear(); } bool Struct::MergePartialFromCodedStream( @@ -329,7 +337,7 @@ bool Struct::MergePartialFromCodedStream( // map<string, .google.protobuf.Value> fields = 1; case 1: { if (static_cast< ::google::protobuf::uint8>(tag) == - static_cast< ::google::protobuf::uint8>(10u)) { + static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) { Struct_FieldsEntry::Parser< ::google::protobuf::internal::MapField< Struct_FieldsEntry, ::std::string, ::google::protobuf::Value, @@ -351,12 +359,11 @@ bool Struct::MergePartialFromCodedStream( default: { handle_unusual: - if (tag == 0 || - ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == - ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + if (tag == 0) { goto success; } - DO_(::google::protobuf::internal::WireFormatLite::SkipField(input, tag)); + DO_(::google::protobuf::internal::WireFormat::SkipField( + input, tag, _internal_metadata_.mutable_unknown_fields())); break; } } @@ -431,6 +438,10 @@ void Struct::SerializeWithCachedSizes( } } + if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { + ::google::protobuf::internal::WireFormat::SerializeUnknownFields( + (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output); + } // @@protoc_insertion_point(serialize_end:google.protobuf.Struct) } @@ -500,6 +511,10 @@ void Struct::SerializeWithCachedSizes( } } + if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { + target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray( + (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target); + } // @@protoc_insertion_point(serialize_to_array_end:google.protobuf.Struct) return target; } @@ -508,6 +523,11 @@ size_t Struct::ByteSizeLong() const { // @@protoc_insertion_point(message_byte_size_start:google.protobuf.Struct) size_t total_size = 0; + if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { + total_size += + ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize( + (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance())); + } // map<string, .google.protobuf.Value> fields = 1; total_size += 1 * ::google::protobuf::internal::FromIntSize(this->fields_size()); @@ -598,8 +618,10 @@ void Struct::UnsafeArenaSwap(Struct* other) { InternalSwap(other); } void Struct::InternalSwap(Struct* other) { + using std::swap; fields_.Swap(&other->fields_); - std::swap(_cached_size_, other->_cached_size_); + _internal_metadata_.Swap(&other->_internal_metadata_); + swap(_cached_size_, other->_cached_size_); } ::google::protobuf::Metadata Struct::GetMetadata() const { @@ -707,6 +729,7 @@ Value::~Value() { void Value::SharedDtor() { ::google::protobuf::Arena* arena = GetArenaNoVirtual(); + GOOGLE_DCHECK(arena == NULL); if (arena != NULL) { return; } @@ -783,7 +806,12 @@ void Value::clear_kind() { void Value::Clear() { // @@protoc_insertion_point(message_clear_start:google.protobuf.Value) + ::google::protobuf::uint32 cached_has_bits = 0; + // Prevent compiler warnings about cached_has_bits being unused + (void) cached_has_bits; + clear_kind(); + _internal_metadata_.Clear(); } bool Value::MergePartialFromCodedStream( @@ -799,7 +827,7 @@ bool Value::MergePartialFromCodedStream( // .google.protobuf.NullValue null_value = 1; case 1: { if (static_cast< ::google::protobuf::uint8>(tag) == - static_cast< ::google::protobuf::uint8>(8u)) { + static_cast< ::google::protobuf::uint8>(8u /* 8 & 0xFF */)) { int value; DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< int, ::google::protobuf::internal::WireFormatLite::TYPE_ENUM>( @@ -814,7 +842,7 @@ bool Value::MergePartialFromCodedStream( // double number_value = 2; case 2: { if (static_cast< ::google::protobuf::uint8>(tag) == - static_cast< ::google::protobuf::uint8>(17u)) { + static_cast< ::google::protobuf::uint8>(17u /* 17 & 0xFF */)) { clear_kind(); DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< double, ::google::protobuf::internal::WireFormatLite::TYPE_DOUBLE>( @@ -829,7 +857,7 @@ bool Value::MergePartialFromCodedStream( // string string_value = 3; case 3: { if (static_cast< ::google::protobuf::uint8>(tag) == - static_cast< ::google::protobuf::uint8>(26u)) { + static_cast< ::google::protobuf::uint8>(26u /* 26 & 0xFF */)) { DO_(::google::protobuf::internal::WireFormatLite::ReadString( input, this->mutable_string_value())); DO_(::google::protobuf::internal::WireFormatLite::VerifyUtf8String( @@ -845,7 +873,7 @@ bool Value::MergePartialFromCodedStream( // bool bool_value = 4; case 4: { if (static_cast< ::google::protobuf::uint8>(tag) == - static_cast< ::google::protobuf::uint8>(32u)) { + static_cast< ::google::protobuf::uint8>(32u /* 32 & 0xFF */)) { clear_kind(); DO_((::google::protobuf::internal::WireFormatLite::ReadPrimitive< bool, ::google::protobuf::internal::WireFormatLite::TYPE_BOOL>( @@ -860,7 +888,7 @@ bool Value::MergePartialFromCodedStream( // .google.protobuf.Struct struct_value = 5; case 5: { if (static_cast< ::google::protobuf::uint8>(tag) == - static_cast< ::google::protobuf::uint8>(42u)) { + static_cast< ::google::protobuf::uint8>(42u /* 42 & 0xFF */)) { DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( input, mutable_struct_value())); } else { @@ -872,7 +900,7 @@ bool Value::MergePartialFromCodedStream( // .google.protobuf.ListValue list_value = 6; case 6: { if (static_cast< ::google::protobuf::uint8>(tag) == - static_cast< ::google::protobuf::uint8>(50u)) { + static_cast< ::google::protobuf::uint8>(50u /* 50 & 0xFF */)) { DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( input, mutable_list_value())); } else { @@ -883,12 +911,11 @@ bool Value::MergePartialFromCodedStream( default: { handle_unusual: - if (tag == 0 || - ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == - ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + if (tag == 0) { goto success; } - DO_(::google::protobuf::internal::WireFormatLite::SkipField(input, tag)); + DO_(::google::protobuf::internal::WireFormat::SkipField( + input, tag, _internal_metadata_.mutable_unknown_fields())); break; } } @@ -946,6 +973,10 @@ void Value::SerializeWithCachedSizes( 6, *kind_.list_value_, output); } + if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { + ::google::protobuf::internal::WireFormat::SerializeUnknownFields( + (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output); + } // @@protoc_insertion_point(serialize_end:google.protobuf.Value) } @@ -997,6 +1028,10 @@ void Value::SerializeWithCachedSizes( 6, *kind_.list_value_, deterministic, target); } + if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { + target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray( + (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target); + } // @@protoc_insertion_point(serialize_to_array_end:google.protobuf.Value) return target; } @@ -1005,6 +1040,11 @@ size_t Value::ByteSizeLong() const { // @@protoc_insertion_point(message_byte_size_start:google.protobuf.Value) size_t total_size = 0; + if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { + total_size += + ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize( + (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance())); + } switch (kind_case()) { // .google.protobuf.NullValue null_value = 1; case kNullValue: { @@ -1145,9 +1185,11 @@ void Value::UnsafeArenaSwap(Value* other) { InternalSwap(other); } void Value::InternalSwap(Value* other) { - std::swap(kind_, other->kind_); - std::swap(_oneof_case_[0], other->_oneof_case_[0]); - std::swap(_cached_size_, other->_cached_size_); + using std::swap; + swap(kind_, other->kind_); + swap(_oneof_case_[0], other->_oneof_case_[0]); + _internal_metadata_.Swap(&other->_internal_metadata_); + swap(_cached_size_, other->_cached_size_); } ::google::protobuf::Metadata Value::GetMetadata() const { @@ -1247,6 +1289,19 @@ void Value::set_string_value(const ::std::string& value) { GetArenaNoVirtual()); // @@protoc_insertion_point(field_set:google.protobuf.Value.string_value) } +#if LANG_CXX11 +void Value::set_string_value(::std::string&& value) { + // @@protoc_insertion_point(field_set:google.protobuf.Value.string_value) + if (!has_string_value()) { + clear_kind(); + set_has_string_value(); + kind_.string_value_.UnsafeSetDefault(&::google::protobuf::internal::GetEmptyStringAlreadyInited()); + } + kind_.string_value_.Set( + &::google::protobuf::internal::GetEmptyStringAlreadyInited(), ::std::move(value), GetArenaNoVirtual()); + // @@protoc_insertion_point(field_set_rvalue:google.protobuf.Value.string_value) +} +#endif void Value::set_string_value(const char* value) { GOOGLE_DCHECK(value != NULL); if (!has_string_value()) { @@ -1585,6 +1640,7 @@ ListValue::~ListValue() { void ListValue::SharedDtor() { ::google::protobuf::Arena* arena = GetArenaNoVirtual(); + GOOGLE_DCHECK(arena == NULL); if (arena != NULL) { return; } @@ -1618,7 +1674,12 @@ ListValue* ListValue::New(::google::protobuf::Arena* arena) const { void ListValue::Clear() { // @@protoc_insertion_point(message_clear_start:google.protobuf.ListValue) + ::google::protobuf::uint32 cached_has_bits = 0; + // Prevent compiler warnings about cached_has_bits being unused + (void) cached_has_bits; + values_.Clear(); + _internal_metadata_.Clear(); } bool ListValue::MergePartialFromCodedStream( @@ -1634,7 +1695,7 @@ bool ListValue::MergePartialFromCodedStream( // repeated .google.protobuf.Value values = 1; case 1: { if (static_cast< ::google::protobuf::uint8>(tag) == - static_cast< ::google::protobuf::uint8>(10u)) { + static_cast< ::google::protobuf::uint8>(10u /* 10 & 0xFF */)) { DO_(::google::protobuf::internal::WireFormatLite::ReadMessageNoVirtual( input, add_values())); } else { @@ -1645,12 +1706,11 @@ bool ListValue::MergePartialFromCodedStream( default: { handle_unusual: - if (tag == 0 || - ::google::protobuf::internal::WireFormatLite::GetTagWireType(tag) == - ::google::protobuf::internal::WireFormatLite::WIRETYPE_END_GROUP) { + if (tag == 0) { goto success; } - DO_(::google::protobuf::internal::WireFormatLite::SkipField(input, tag)); + DO_(::google::protobuf::internal::WireFormat::SkipField( + input, tag, _internal_metadata_.mutable_unknown_fields())); break; } } @@ -1677,6 +1737,10 @@ void ListValue::SerializeWithCachedSizes( 1, this->values(static_cast<int>(i)), output); } + if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { + ::google::protobuf::internal::WireFormat::SerializeUnknownFields( + (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), output); + } // @@protoc_insertion_point(serialize_end:google.protobuf.ListValue) } @@ -1695,6 +1759,10 @@ void ListValue::SerializeWithCachedSizes( 1, this->values(static_cast<int>(i)), deterministic, target); } + if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { + target = ::google::protobuf::internal::WireFormat::SerializeUnknownFieldsToArray( + (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance()), target); + } // @@protoc_insertion_point(serialize_to_array_end:google.protobuf.ListValue) return target; } @@ -1703,6 +1771,11 @@ size_t ListValue::ByteSizeLong() const { // @@protoc_insertion_point(message_byte_size_start:google.protobuf.ListValue) size_t total_size = 0; + if ((_internal_metadata_.have_unknown_fields() && ::google::protobuf::internal::GetProto3PreserveUnknownsDefault())) { + total_size += + ::google::protobuf::internal::WireFormat::ComputeUnknownFieldsSize( + (::google::protobuf::internal::GetProto3PreserveUnknownsDefault() ? _internal_metadata_.unknown_fields() : _internal_metadata_.default_instance())); + } // repeated .google.protobuf.Value values = 1; { unsigned int count = static_cast<unsigned int>(this->values_size()); @@ -1784,8 +1857,10 @@ void ListValue::UnsafeArenaSwap(ListValue* other) { InternalSwap(other); } void ListValue::InternalSwap(ListValue* other) { + using std::swap; values_.InternalSwap(&other->values_); - std::swap(_cached_size_, other->_cached_size_); + _internal_metadata_.Swap(&other->_internal_metadata_); + swap(_cached_size_, other->_cached_size_); } ::google::protobuf::Metadata ListValue::GetMetadata() const { |