Refactor repeated field generators with noop changes related to split repeated fields. Also add TSan validation in _internal_mutable_weak_$name$() for weak message fields, which was missing.

PiperOrigin-RevId: 544381907
pull/13179/head
Protobuf Team Bot 2 years ago committed by Copybara-Service
parent 8ec0295ad7
commit 200480e83c
  1. 7
      src/google/protobuf/compiler/cpp/field_generators/enum_field.cc
  2. 31
      src/google/protobuf/compiler/cpp/field_generators/message_field.cc
  3. 3
      src/google/protobuf/compiler/cpp/field_generators/primitive_field.cc
  4. 4
      src/google/protobuf/compiler/cpp/field_generators/string_field.cc
  5. 9
      src/google/protobuf/compiler/plugin.pb.cc
  6. 81
      src/google/protobuf/descriptor.pb.cc
  7. 20
      src/google/protobuf/descriptor.pb.h

@ -195,7 +195,8 @@ void SingularEnum::GenerateInlineAccessorDefinitions(io::Printer* p) const {
return _internal_$name$();
}
inline void $Msg$::set_$name$($Enum$ value) {
$PrepareSplitMessageForWrite$ _internal_set_$name$(value);
$PrepareSplitMessageForWrite$;
_internal_set_$name$(value);
$annotate_set$;
// @@protoc_insertion_point(field_set:$pkg.Msg.field$)
}
@ -271,9 +272,9 @@ class RepeatedEnum : public FieldGeneratorBase {
}
void GenerateSwappingCode(io::Printer* p) const override {
ABSL_CHECK(!ShouldSplit(descriptor_, options_));
p->Emit(R"cc(
_internal_mutable_$name$()->InternalSwap(
other->_internal_mutable_$name$());
$field_$.InternalSwap(&other->$field_$);
)cc");
}

@ -832,27 +832,25 @@ void RepeatedMessage::GenerateInlineAccessorDefinitions(io::Printer* p) const {
"}\n");
p->Emit(R"cc(
inline const $pb$::RepeatedPtrField<$Submsg$>&
$classname$::_internal_$name$() const {
inline const $pb$::$Weak$RepeatedPtrField<$Submsg$>&
$Msg$::_internal$_weak$_$name$() const {
$TsanDetectConcurrentRead$;
return $field$$.weak$;
return $field_$;
}
inline $pb$::RepeatedPtrField<$Submsg$>*
$classname$::_internal_mutable_$name$() {
inline $pb$::$Weak$RepeatedPtrField<$Submsg$>*
$Msg$::_internal_mutable$_weak$_$name$() {
$TsanDetectConcurrentRead$;
return &$field$$.weak$;
return &$field_$;
}
)cc");
if (weak_) {
p->Emit(R"cc(
inline const $pb$::WeakRepeatedPtrField<$Submsg$>&
$Msg$::_internal_weak_$name$() const {
$TsanDetectConcurrentRead$;
return $field$;
inline const $pb$::RepeatedPtrField<$Submsg$>& $Msg$::_internal_$name$()
const {
return _internal_weak_$name$().weak;
}
inline $pb$::WeakRepeatedPtrField<$Submsg$>*
$Msg$::_internal_mutable_weak_$name$() {
return &$field$;
inline $pb$::RepeatedPtrField<$Submsg$>* $Msg$::_internal_mutable_$name$() {
return &_internal_mutable_weak_$name$()->weak;
}
)cc");
}
@ -869,9 +867,10 @@ void RepeatedMessage::GenerateMergingCode(io::Printer* p) const {
}
void RepeatedMessage::GenerateSwappingCode(io::Printer* p) const {
p->Emit(
"_internal_mutable$_weak$_$name$()->InternalSwap(other->_internal_"
"mutable$_weak$_$name$());\n");
ABSL_CHECK(!ShouldSplit(descriptor_, options_));
p->Emit(R"cc(
$field_$.InternalSwap(&other->$field_$);
)cc");
}
void RepeatedMessage::GenerateConstructorCode(io::Printer* p) const {

@ -323,11 +323,12 @@ class RepeatedPrimitive final : public FieldGeneratorBase {
void GenerateMergingCode(io::Printer* p) const override {
p->Emit(R"cc(
_this->$field_$.MergeFrom(from.$field_$);
_this->_internal_mutable_$name$()->MergeFrom(from._internal_$name$());
)cc");
}
void GenerateSwappingCode(io::Printer* p) const override {
ABSL_CHECK(!ShouldSplit(descriptor_, options_));
p->Emit(R"cc(
$field_$.InternalSwap(&other->$field_$);
)cc");

@ -727,9 +727,9 @@ class RepeatedString : public FieldGeneratorBase {
}
void GenerateSwappingCode(io::Printer* p) const override {
ABSL_CHECK(!ShouldSplit(descriptor_, options_));
p->Emit(R"cc(
_internal_mutable_$name$()->InternalSwap(
other->_internal_mutable_$name$());
$field_$.InternalSwap(&other->$field_$);
)cc");
}

@ -942,10 +942,9 @@ void CodeGeneratorRequest::InternalSwap(CodeGeneratorRequest* other) {
auto* rhs_arena = other->GetArenaForAllocation();
_internal_metadata_.InternalSwap(&other->_internal_metadata_);
swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
_internal_mutable_file_to_generate()->InternalSwap(
other->_internal_mutable_file_to_generate());
_internal_mutable_proto_file()->InternalSwap(other->_internal_mutable_proto_file());
_internal_mutable_source_file_descriptors()->InternalSwap(other->_internal_mutable_source_file_descriptors());
_impl_.file_to_generate_.InternalSwap(&other->_impl_.file_to_generate_);
_impl_.proto_file_.InternalSwap(&other->_impl_.proto_file_);
_impl_.source_file_descriptors_.InternalSwap(&other->_impl_.source_file_descriptors_);
::_pbi::ArenaStringPtr::InternalSwap(&_impl_.parameter_, lhs_arena,
&other->_impl_.parameter_, rhs_arena);
swap(_impl_.compiler_version_, other->_impl_.compiler_version_);
@ -1565,7 +1564,7 @@ void CodeGeneratorResponse::InternalSwap(CodeGeneratorResponse* other) {
auto* rhs_arena = other->GetArenaForAllocation();
_internal_metadata_.InternalSwap(&other->_internal_metadata_);
swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
_internal_mutable_file()->InternalSwap(other->_internal_mutable_file());
_impl_.file_.InternalSwap(&other->_impl_.file_);
::_pbi::ArenaStringPtr::InternalSwap(&_impl_.error_, lhs_arena,
&other->_impl_.error_, rhs_arena);
swap(_impl_.supported_features_, other->_impl_.supported_features_);

@ -2175,7 +2175,7 @@ PROTOBUF_NOINLINE bool FileDescriptorSet::IsInitialized() const {
void FileDescriptorSet::InternalSwap(FileDescriptorSet* other) {
using std::swap;
_internal_metadata_.InternalSwap(&other->_internal_metadata_);
_internal_mutable_file()->InternalSwap(other->_internal_mutable_file());
_impl_.file_.InternalSwap(&other->_impl_.file_);
}
::google::protobuf::Metadata FileDescriptorSet::GetMetadata() const {
@ -2745,8 +2745,8 @@ void FileDescriptorProto::MergeImpl(::google::protobuf::Message& to_msg, const :
_this->_internal_mutable_enum_type()->MergeFrom(from._internal_enum_type());
_this->_internal_mutable_service()->MergeFrom(from._internal_service());
_this->_internal_mutable_extension()->MergeFrom(from._internal_extension());
_this->_impl_.public_dependency_.MergeFrom(from._impl_.public_dependency_);
_this->_impl_.weak_dependency_.MergeFrom(from._impl_.weak_dependency_);
_this->_internal_mutable_public_dependency()->MergeFrom(from._internal_public_dependency());
_this->_internal_mutable_weak_dependency()->MergeFrom(from._internal_weak_dependency());
cached_has_bits = from._impl_._has_bits_[0];
if (cached_has_bits & 0x0000003fu) {
if (cached_has_bits & 0x00000001u) {
@ -2801,12 +2801,11 @@ void FileDescriptorProto::InternalSwap(FileDescriptorProto* other) {
auto* rhs_arena = other->GetArenaForAllocation();
_internal_metadata_.InternalSwap(&other->_internal_metadata_);
swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
_internal_mutable_dependency()->InternalSwap(
other->_internal_mutable_dependency());
_internal_mutable_message_type()->InternalSwap(other->_internal_mutable_message_type());
_internal_mutable_enum_type()->InternalSwap(other->_internal_mutable_enum_type());
_internal_mutable_service()->InternalSwap(other->_internal_mutable_service());
_internal_mutable_extension()->InternalSwap(other->_internal_mutable_extension());
_impl_.dependency_.InternalSwap(&other->_impl_.dependency_);
_impl_.message_type_.InternalSwap(&other->_impl_.message_type_);
_impl_.enum_type_.InternalSwap(&other->_impl_.enum_type_);
_impl_.service_.InternalSwap(&other->_impl_.service_);
_impl_.extension_.InternalSwap(&other->_impl_.extension_);
_impl_.public_dependency_.InternalSwap(&other->_impl_.public_dependency_);
_impl_.weak_dependency_.InternalSwap(&other->_impl_.weak_dependency_);
::_pbi::ArenaStringPtr::InternalSwap(&_impl_.name_, lhs_arena,
@ -3795,15 +3794,14 @@ void DescriptorProto::InternalSwap(DescriptorProto* other) {
auto* rhs_arena = other->GetArenaForAllocation();
_internal_metadata_.InternalSwap(&other->_internal_metadata_);
swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
_internal_mutable_field()->InternalSwap(other->_internal_mutable_field());
_internal_mutable_nested_type()->InternalSwap(other->_internal_mutable_nested_type());
_internal_mutable_enum_type()->InternalSwap(other->_internal_mutable_enum_type());
_internal_mutable_extension_range()->InternalSwap(other->_internal_mutable_extension_range());
_internal_mutable_extension()->InternalSwap(other->_internal_mutable_extension());
_internal_mutable_oneof_decl()->InternalSwap(other->_internal_mutable_oneof_decl());
_internal_mutable_reserved_range()->InternalSwap(other->_internal_mutable_reserved_range());
_internal_mutable_reserved_name()->InternalSwap(
other->_internal_mutable_reserved_name());
_impl_.field_.InternalSwap(&other->_impl_.field_);
_impl_.nested_type_.InternalSwap(&other->_impl_.nested_type_);
_impl_.enum_type_.InternalSwap(&other->_impl_.enum_type_);
_impl_.extension_range_.InternalSwap(&other->_impl_.extension_range_);
_impl_.extension_.InternalSwap(&other->_impl_.extension_);
_impl_.oneof_decl_.InternalSwap(&other->_impl_.oneof_decl_);
_impl_.reserved_range_.InternalSwap(&other->_impl_.reserved_range_);
_impl_.reserved_name_.InternalSwap(&other->_impl_.reserved_name_);
::_pbi::ArenaStringPtr::InternalSwap(&_impl_.name_, lhs_arena,
&other->_impl_.name_, rhs_arena);
swap(_impl_.options_, other->_impl_.options_);
@ -4439,8 +4437,8 @@ void ExtensionRangeOptions::InternalSwap(ExtensionRangeOptions* other) {
_impl_._extensions_.InternalSwap(&other->_impl_._extensions_);
_internal_metadata_.InternalSwap(&other->_internal_metadata_);
swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
_internal_mutable_declaration()->InternalSwap(other->_internal_mutable_declaration());
_internal_mutable_uninterpreted_option()->InternalSwap(other->_internal_mutable_uninterpreted_option());
_impl_.declaration_.InternalSwap(&other->_impl_.declaration_);
_impl_.uninterpreted_option_.InternalSwap(&other->_impl_.uninterpreted_option_);
swap(_impl_.verification_, other->_impl_.verification_);
}
@ -5858,10 +5856,9 @@ void EnumDescriptorProto::InternalSwap(EnumDescriptorProto* other) {
auto* rhs_arena = other->GetArenaForAllocation();
_internal_metadata_.InternalSwap(&other->_internal_metadata_);
swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
_internal_mutable_value()->InternalSwap(other->_internal_mutable_value());
_internal_mutable_reserved_range()->InternalSwap(other->_internal_mutable_reserved_range());
_internal_mutable_reserved_name()->InternalSwap(
other->_internal_mutable_reserved_name());
_impl_.value_.InternalSwap(&other->_impl_.value_);
_impl_.reserved_range_.InternalSwap(&other->_impl_.reserved_range_);
_impl_.reserved_name_.InternalSwap(&other->_impl_.reserved_name_);
::_pbi::ArenaStringPtr::InternalSwap(&_impl_.name_, lhs_arena,
&other->_impl_.name_, rhs_arena);
swap(_impl_.options_, other->_impl_.options_);
@ -6441,7 +6438,7 @@ void ServiceDescriptorProto::InternalSwap(ServiceDescriptorProto* other) {
auto* rhs_arena = other->GetArenaForAllocation();
_internal_metadata_.InternalSwap(&other->_internal_metadata_);
swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
_internal_mutable_method()->InternalSwap(other->_internal_mutable_method());
_impl_.method_.InternalSwap(&other->_impl_.method_);
::_pbi::ArenaStringPtr::InternalSwap(&_impl_.name_, lhs_arena,
&other->_impl_.name_, rhs_arena);
swap(_impl_.options_, other->_impl_.options_);
@ -7806,7 +7803,7 @@ void FileOptions::InternalSwap(FileOptions* other) {
auto* rhs_arena = other->GetArenaForAllocation();
_internal_metadata_.InternalSwap(&other->_internal_metadata_);
swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
_internal_mutable_uninterpreted_option()->InternalSwap(other->_internal_mutable_uninterpreted_option());
_impl_.uninterpreted_option_.InternalSwap(&other->_impl_.uninterpreted_option_);
::_pbi::ArenaStringPtr::InternalSwap(&_impl_.java_package_, lhs_arena,
&other->_impl_.java_package_, rhs_arena);
::_pbi::ArenaStringPtr::InternalSwap(&_impl_.java_outer_classname_, lhs_arena,
@ -8175,7 +8172,7 @@ void MessageOptions::InternalSwap(MessageOptions* other) {
_impl_._extensions_.InternalSwap(&other->_impl_._extensions_);
_internal_metadata_.InternalSwap(&other->_internal_metadata_);
swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
_internal_mutable_uninterpreted_option()->InternalSwap(other->_internal_mutable_uninterpreted_option());
_impl_.uninterpreted_option_.InternalSwap(&other->_impl_.uninterpreted_option_);
::google::protobuf::internal::memswap<
PROTOBUF_FIELD_OFFSET(MessageOptions, _impl_.deprecated_legacy_json_field_conflicts_)
+ sizeof(MessageOptions::_impl_.deprecated_legacy_json_field_conflicts_)
@ -8704,9 +8701,8 @@ void FieldOptions::InternalSwap(FieldOptions* other) {
_impl_._extensions_.InternalSwap(&other->_impl_._extensions_);
_internal_metadata_.InternalSwap(&other->_internal_metadata_);
swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
_internal_mutable_targets()->InternalSwap(
other->_internal_mutable_targets());
_internal_mutable_uninterpreted_option()->InternalSwap(other->_internal_mutable_uninterpreted_option());
_impl_.targets_.InternalSwap(&other->_impl_.targets_);
_impl_.uninterpreted_option_.InternalSwap(&other->_impl_.uninterpreted_option_);
::google::protobuf::internal::memswap<
PROTOBUF_FIELD_OFFSET(FieldOptions, _impl_.target_obsolete_do_not_use_)
+ sizeof(FieldOptions::_impl_.target_obsolete_do_not_use_)
@ -8903,7 +8899,7 @@ void OneofOptions::InternalSwap(OneofOptions* other) {
using std::swap;
_impl_._extensions_.InternalSwap(&other->_impl_._extensions_);
_internal_metadata_.InternalSwap(&other->_internal_metadata_);
_internal_mutable_uninterpreted_option()->InternalSwap(other->_internal_mutable_uninterpreted_option());
_impl_.uninterpreted_option_.InternalSwap(&other->_impl_.uninterpreted_option_);
}
::google::protobuf::Metadata OneofOptions::GetMetadata() const {
@ -9197,7 +9193,7 @@ void EnumOptions::InternalSwap(EnumOptions* other) {
_impl_._extensions_.InternalSwap(&other->_impl_._extensions_);
_internal_metadata_.InternalSwap(&other->_internal_metadata_);
swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
_internal_mutable_uninterpreted_option()->InternalSwap(other->_internal_mutable_uninterpreted_option());
_impl_.uninterpreted_option_.InternalSwap(&other->_impl_.uninterpreted_option_);
::google::protobuf::internal::memswap<
PROTOBUF_FIELD_OFFSET(EnumOptions, _impl_.deprecated_legacy_json_field_conflicts_)
+ sizeof(EnumOptions::_impl_.deprecated_legacy_json_field_conflicts_)
@ -9466,7 +9462,7 @@ void EnumValueOptions::InternalSwap(EnumValueOptions* other) {
_impl_._extensions_.InternalSwap(&other->_impl_._extensions_);
_internal_metadata_.InternalSwap(&other->_internal_metadata_);
swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
_internal_mutable_uninterpreted_option()->InternalSwap(other->_internal_mutable_uninterpreted_option());
_impl_.uninterpreted_option_.InternalSwap(&other->_impl_.uninterpreted_option_);
::google::protobuf::internal::memswap<
PROTOBUF_FIELD_OFFSET(EnumValueOptions, _impl_.debug_redact_)
+ sizeof(EnumValueOptions::_impl_.debug_redact_)
@ -9703,7 +9699,7 @@ void ServiceOptions::InternalSwap(ServiceOptions* other) {
_impl_._extensions_.InternalSwap(&other->_impl_._extensions_);
_internal_metadata_.InternalSwap(&other->_internal_metadata_);
swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
_internal_mutable_uninterpreted_option()->InternalSwap(other->_internal_mutable_uninterpreted_option());
_impl_.uninterpreted_option_.InternalSwap(&other->_impl_.uninterpreted_option_);
swap(_impl_.deprecated_, other->_impl_.deprecated_);
}
@ -9975,7 +9971,7 @@ void MethodOptions::InternalSwap(MethodOptions* other) {
_impl_._extensions_.InternalSwap(&other->_impl_._extensions_);
_internal_metadata_.InternalSwap(&other->_internal_metadata_);
swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
_internal_mutable_uninterpreted_option()->InternalSwap(other->_internal_mutable_uninterpreted_option());
_impl_.uninterpreted_option_.InternalSwap(&other->_impl_.uninterpreted_option_);
::google::protobuf::internal::memswap<
PROTOBUF_FIELD_OFFSET(MethodOptions, _impl_.idempotency_level_)
+ sizeof(MethodOptions::_impl_.idempotency_level_)
@ -10640,7 +10636,7 @@ void UninterpretedOption::InternalSwap(UninterpretedOption* other) {
auto* rhs_arena = other->GetArenaForAllocation();
_internal_metadata_.InternalSwap(&other->_internal_metadata_);
swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
_internal_mutable_name()->InternalSwap(other->_internal_mutable_name());
_impl_.name_.InternalSwap(&other->_impl_.name_);
::_pbi::ArenaStringPtr::InternalSwap(&_impl_.identifier_value_, lhs_arena,
&other->_impl_.identifier_value_, rhs_arena);
::_pbi::ArenaStringPtr::InternalSwap(&_impl_.string_value_, lhs_arena,
@ -10974,8 +10970,8 @@ void SourceCodeInfo_Location::MergeImpl(::google::protobuf::Message& to_msg, con
::uint32_t cached_has_bits = 0;
(void) cached_has_bits;
_this->_impl_.path_.MergeFrom(from._impl_.path_);
_this->_impl_.span_.MergeFrom(from._impl_.span_);
_this->_internal_mutable_path()->MergeFrom(from._internal_path());
_this->_internal_mutable_span()->MergeFrom(from._internal_span());
_this->_internal_mutable_leading_detached_comments()->MergeFrom(from._internal_leading_detached_comments());
cached_has_bits = from._impl_._has_bits_[0];
if (cached_has_bits & 0x00000003u) {
@ -11008,8 +11004,7 @@ void SourceCodeInfo_Location::InternalSwap(SourceCodeInfo_Location* other) {
swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
_impl_.path_.InternalSwap(&other->_impl_.path_);
_impl_.span_.InternalSwap(&other->_impl_.span_);
_internal_mutable_leading_detached_comments()->InternalSwap(
other->_internal_mutable_leading_detached_comments());
_impl_.leading_detached_comments_.InternalSwap(&other->_impl_.leading_detached_comments_);
::_pbi::ArenaStringPtr::InternalSwap(&_impl_.leading_comments_, lhs_arena,
&other->_impl_.leading_comments_, rhs_arena);
::_pbi::ArenaStringPtr::InternalSwap(&_impl_.trailing_comments_, lhs_arena,
@ -11184,7 +11179,7 @@ PROTOBUF_NOINLINE bool SourceCodeInfo::IsInitialized() const {
void SourceCodeInfo::InternalSwap(SourceCodeInfo* other) {
using std::swap;
_internal_metadata_.InternalSwap(&other->_internal_metadata_);
_internal_mutable_location()->InternalSwap(other->_internal_mutable_location());
_impl_.location_.InternalSwap(&other->_impl_.location_);
}
::google::protobuf::Metadata SourceCodeInfo::GetMetadata() const {
@ -11484,7 +11479,7 @@ void GeneratedCodeInfo_Annotation::MergeImpl(::google::protobuf::Message& to_msg
::uint32_t cached_has_bits = 0;
(void) cached_has_bits;
_this->_impl_.path_.MergeFrom(from._impl_.path_);
_this->_internal_mutable_path()->MergeFrom(from._internal_path());
cached_has_bits = from._impl_._has_bits_[0];
if (cached_has_bits & 0x0000000fu) {
if (cached_has_bits & 0x00000001u) {
@ -11700,7 +11695,7 @@ PROTOBUF_NOINLINE bool GeneratedCodeInfo::IsInitialized() const {
void GeneratedCodeInfo::InternalSwap(GeneratedCodeInfo* other) {
using std::swap;
_internal_metadata_.InternalSwap(&other->_internal_metadata_);
_internal_mutable_annotation()->InternalSwap(other->_internal_mutable_annotation());
_impl_.annotation_.InternalSwap(&other->_impl_.annotation_);
}
::google::protobuf::Metadata GeneratedCodeInfo::GetMetadata() const {

@ -10738,7 +10738,7 @@ inline ::google::protobuf::ExtensionRangeOptions_VerificationState ExtensionRang
return _internal_verification();
}
inline void ExtensionRangeOptions::set_verification(::google::protobuf::ExtensionRangeOptions_VerificationState value) {
_internal_set_verification(value);
_internal_set_verification(value);
// @@protoc_insertion_point(field_set:google.protobuf.ExtensionRangeOptions.verification)
}
inline ::google::protobuf::ExtensionRangeOptions_VerificationState ExtensionRangeOptions::_internal_verification() const {
@ -10866,7 +10866,7 @@ inline ::google::protobuf::FieldDescriptorProto_Label FieldDescriptorProto::labe
return _internal_label();
}
inline void FieldDescriptorProto::set_label(::google::protobuf::FieldDescriptorProto_Label value) {
_internal_set_label(value);
_internal_set_label(value);
// @@protoc_insertion_point(field_set:google.protobuf.FieldDescriptorProto.label)
}
inline ::google::protobuf::FieldDescriptorProto_Label FieldDescriptorProto::_internal_label() const {
@ -10894,7 +10894,7 @@ inline ::google::protobuf::FieldDescriptorProto_Type FieldDescriptorProto::type(
return _internal_type();
}
inline void FieldDescriptorProto::set_type(::google::protobuf::FieldDescriptorProto_Type value) {
_internal_set_type(value);
_internal_set_type(value);
// @@protoc_insertion_point(field_set:google.protobuf.FieldDescriptorProto.type)
}
inline ::google::protobuf::FieldDescriptorProto_Type FieldDescriptorProto::_internal_type() const {
@ -12927,7 +12927,7 @@ inline ::google::protobuf::FileOptions_OptimizeMode FileOptions::optimize_for()
return _internal_optimize_for();
}
inline void FileOptions::set_optimize_for(::google::protobuf::FileOptions_OptimizeMode value) {
_internal_set_optimize_for(value);
_internal_set_optimize_for(value);
// @@protoc_insertion_point(field_set:google.protobuf.FileOptions.optimize_for)
}
inline ::google::protobuf::FileOptions_OptimizeMode FileOptions::_internal_optimize_for() const {
@ -13904,7 +13904,7 @@ inline ::google::protobuf::FieldOptions_CType FieldOptions::ctype() const {
return _internal_ctype();
}
inline void FieldOptions::set_ctype(::google::protobuf::FieldOptions_CType value) {
_internal_set_ctype(value);
_internal_set_ctype(value);
// @@protoc_insertion_point(field_set:google.protobuf.FieldOptions.ctype)
}
inline ::google::protobuf::FieldOptions_CType FieldOptions::_internal_ctype() const {
@ -13959,7 +13959,7 @@ inline ::google::protobuf::FieldOptions_JSType FieldOptions::jstype() const {
return _internal_jstype();
}
inline void FieldOptions::set_jstype(::google::protobuf::FieldOptions_JSType value) {
_internal_set_jstype(value);
_internal_set_jstype(value);
// @@protoc_insertion_point(field_set:google.protobuf.FieldOptions.jstype)
}
inline ::google::protobuf::FieldOptions_JSType FieldOptions::_internal_jstype() const {
@ -14122,7 +14122,7 @@ inline ::google::protobuf::FieldOptions_OptionRetention FieldOptions::retention(
return _internal_retention();
}
inline void FieldOptions::set_retention(::google::protobuf::FieldOptions_OptionRetention value) {
_internal_set_retention(value);
_internal_set_retention(value);
// @@protoc_insertion_point(field_set:google.protobuf.FieldOptions.retention)
}
inline ::google::protobuf::FieldOptions_OptionRetention FieldOptions::_internal_retention() const {
@ -14239,7 +14239,7 @@ inline ::google::protobuf::FieldOptions_OptionTargetType FieldOptions::target_ob
return _internal_target_obsolete_do_not_use();
}
inline void FieldOptions::set_target_obsolete_do_not_use(::google::protobuf::FieldOptions_OptionTargetType value) {
_internal_set_target_obsolete_do_not_use(value);
_internal_set_target_obsolete_do_not_use(value);
// @@protoc_insertion_point(field_set:google.protobuf.FieldOptions.target_obsolete_do_not_use)
}
inline ::google::protobuf::FieldOptions_OptionTargetType FieldOptions::_internal_target_obsolete_do_not_use() const {
@ -14660,7 +14660,7 @@ inline ::google::protobuf::MethodOptions_IdempotencyLevel MethodOptions::idempot
return _internal_idempotency_level();
}
inline void MethodOptions::set_idempotency_level(::google::protobuf::MethodOptions_IdempotencyLevel value) {
_internal_set_idempotency_level(value);
_internal_set_idempotency_level(value);
// @@protoc_insertion_point(field_set:google.protobuf.MethodOptions.idempotency_level)
}
inline ::google::protobuf::MethodOptions_IdempotencyLevel MethodOptions::_internal_idempotency_level() const {
@ -15713,7 +15713,7 @@ inline ::google::protobuf::GeneratedCodeInfo_Annotation_Semantic GeneratedCodeIn
return _internal_semantic();
}
inline void GeneratedCodeInfo_Annotation::set_semantic(::google::protobuf::GeneratedCodeInfo_Annotation_Semantic value) {
_internal_set_semantic(value);
_internal_set_semantic(value);
// @@protoc_insertion_point(field_set:google.protobuf.GeneratedCodeInfo.Annotation.semantic)
}
inline ::google::protobuf::GeneratedCodeInfo_Annotation_Semantic GeneratedCodeInfo_Annotation::_internal_semantic() const {

Loading…
Cancel
Save