xref: /aosp_15_r20/external/cronet/third_party/protobuf/src/google/protobuf/compiler/plugin.pb.cc (revision 6777b5387eb2ff775bb5750e3f5d96f37fb7352b)
1 // Generated by the protocol buffer compiler.  DO NOT EDIT!
2 // source: google/protobuf/compiler/plugin.proto
3 
4 #include <google/protobuf/compiler/plugin.pb.h>
5 
6 #include <algorithm>
7 
8 #include <google/protobuf/io/coded_stream.h>
9 #include <google/protobuf/extension_set.h>
10 #include <google/protobuf/wire_format_lite.h>
11 #include <google/protobuf/descriptor.h>
12 #include <google/protobuf/generated_message_reflection.h>
13 #include <google/protobuf/reflection_ops.h>
14 #include <google/protobuf/wire_format.h>
15 // @@protoc_insertion_point(includes)
16 #include <google/protobuf/port_def.inc>
17 
18 PROTOBUF_PRAGMA_INIT_SEG
19 
20 namespace _pb = ::PROTOBUF_NAMESPACE_ID;
21 namespace _pbi = _pb::internal;
22 
23 PROTOBUF_NAMESPACE_OPEN
24 namespace compiler {
Version(::_pbi::ConstantInitialized)25 PROTOBUF_CONSTEXPR Version::Version(
26     ::_pbi::ConstantInitialized): _impl_{
27     /*decltype(_impl_._has_bits_)*/{}
28   , /*decltype(_impl_._cached_size_)*/{}
29   , /*decltype(_impl_.suffix_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}}
30   , /*decltype(_impl_.major_)*/0
31   , /*decltype(_impl_.minor_)*/0
32   , /*decltype(_impl_.patch_)*/0} {}
33 struct VersionDefaultTypeInternal {
VersionDefaultTypeInternalcompiler::VersionDefaultTypeInternal34   PROTOBUF_CONSTEXPR VersionDefaultTypeInternal()
35       : _instance(::_pbi::ConstantInitialized{}) {}
~VersionDefaultTypeInternalcompiler::VersionDefaultTypeInternal36   ~VersionDefaultTypeInternal() {}
37   union {
38     Version _instance;
39   };
40 };
41 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 VersionDefaultTypeInternal _Version_default_instance_;
CodeGeneratorRequest(::_pbi::ConstantInitialized)42 PROTOBUF_CONSTEXPR CodeGeneratorRequest::CodeGeneratorRequest(
43     ::_pbi::ConstantInitialized): _impl_{
44     /*decltype(_impl_._has_bits_)*/{}
45   , /*decltype(_impl_._cached_size_)*/{}
46   , /*decltype(_impl_.file_to_generate_)*/{}
47   , /*decltype(_impl_.proto_file_)*/{}
48   , /*decltype(_impl_.parameter_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}}
49   , /*decltype(_impl_.compiler_version_)*/nullptr} {}
50 struct CodeGeneratorRequestDefaultTypeInternal {
CodeGeneratorRequestDefaultTypeInternalcompiler::CodeGeneratorRequestDefaultTypeInternal51   PROTOBUF_CONSTEXPR CodeGeneratorRequestDefaultTypeInternal()
52       : _instance(::_pbi::ConstantInitialized{}) {}
~CodeGeneratorRequestDefaultTypeInternalcompiler::CodeGeneratorRequestDefaultTypeInternal53   ~CodeGeneratorRequestDefaultTypeInternal() {}
54   union {
55     CodeGeneratorRequest _instance;
56   };
57 };
58 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 CodeGeneratorRequestDefaultTypeInternal _CodeGeneratorRequest_default_instance_;
CodeGeneratorResponse_File(::_pbi::ConstantInitialized)59 PROTOBUF_CONSTEXPR CodeGeneratorResponse_File::CodeGeneratorResponse_File(
60     ::_pbi::ConstantInitialized): _impl_{
61     /*decltype(_impl_._has_bits_)*/{}
62   , /*decltype(_impl_._cached_size_)*/{}
63   , /*decltype(_impl_.name_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}}
64   , /*decltype(_impl_.insertion_point_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}}
65   , /*decltype(_impl_.content_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}}
66   , /*decltype(_impl_.generated_code_info_)*/nullptr} {}
67 struct CodeGeneratorResponse_FileDefaultTypeInternal {
CodeGeneratorResponse_FileDefaultTypeInternalcompiler::CodeGeneratorResponse_FileDefaultTypeInternal68   PROTOBUF_CONSTEXPR CodeGeneratorResponse_FileDefaultTypeInternal()
69       : _instance(::_pbi::ConstantInitialized{}) {}
~CodeGeneratorResponse_FileDefaultTypeInternalcompiler::CodeGeneratorResponse_FileDefaultTypeInternal70   ~CodeGeneratorResponse_FileDefaultTypeInternal() {}
71   union {
72     CodeGeneratorResponse_File _instance;
73   };
74 };
75 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 CodeGeneratorResponse_FileDefaultTypeInternal _CodeGeneratorResponse_File_default_instance_;
CodeGeneratorResponse(::_pbi::ConstantInitialized)76 PROTOBUF_CONSTEXPR CodeGeneratorResponse::CodeGeneratorResponse(
77     ::_pbi::ConstantInitialized): _impl_{
78     /*decltype(_impl_._has_bits_)*/{}
79   , /*decltype(_impl_._cached_size_)*/{}
80   , /*decltype(_impl_.file_)*/{}
81   , /*decltype(_impl_.error_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}}
82   , /*decltype(_impl_.supported_features_)*/uint64_t{0u}} {}
83 struct CodeGeneratorResponseDefaultTypeInternal {
CodeGeneratorResponseDefaultTypeInternalcompiler::CodeGeneratorResponseDefaultTypeInternal84   PROTOBUF_CONSTEXPR CodeGeneratorResponseDefaultTypeInternal()
85       : _instance(::_pbi::ConstantInitialized{}) {}
~CodeGeneratorResponseDefaultTypeInternalcompiler::CodeGeneratorResponseDefaultTypeInternal86   ~CodeGeneratorResponseDefaultTypeInternal() {}
87   union {
88     CodeGeneratorResponse _instance;
89   };
90 };
91 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 CodeGeneratorResponseDefaultTypeInternal _CodeGeneratorResponse_default_instance_;
92 }  // namespace compiler
93 PROTOBUF_NAMESPACE_CLOSE
94 static ::_pb::Metadata file_level_metadata_google_2fprotobuf_2fcompiler_2fplugin_2eproto[4];
95 static const ::_pb::EnumDescriptor* file_level_enum_descriptors_google_2fprotobuf_2fcompiler_2fplugin_2eproto[1];
96 static constexpr ::_pb::ServiceDescriptor const** file_level_service_descriptors_google_2fprotobuf_2fcompiler_2fplugin_2eproto = nullptr;
97 
98 const uint32_t TableStruct_google_2fprotobuf_2fcompiler_2fplugin_2eproto::offsets[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = {
99   PROTOBUF_FIELD_OFFSET(::PROTOBUF_NAMESPACE_ID::compiler::Version, _impl_._has_bits_),
100   PROTOBUF_FIELD_OFFSET(::PROTOBUF_NAMESPACE_ID::compiler::Version, _internal_metadata_),
101   ~0u,  // no _extensions_
102   ~0u,  // no _oneof_case_
103   ~0u,  // no _weak_field_map_
104   ~0u,  // no _inlined_string_donated_
105   PROTOBUF_FIELD_OFFSET(::PROTOBUF_NAMESPACE_ID::compiler::Version, _impl_.major_),
106   PROTOBUF_FIELD_OFFSET(::PROTOBUF_NAMESPACE_ID::compiler::Version, _impl_.minor_),
107   PROTOBUF_FIELD_OFFSET(::PROTOBUF_NAMESPACE_ID::compiler::Version, _impl_.patch_),
108   PROTOBUF_FIELD_OFFSET(::PROTOBUF_NAMESPACE_ID::compiler::Version, _impl_.suffix_),
109   1,
110   2,
111   3,
112   0,
113   PROTOBUF_FIELD_OFFSET(::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorRequest, _impl_._has_bits_),
114   PROTOBUF_FIELD_OFFSET(::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorRequest, _internal_metadata_),
115   ~0u,  // no _extensions_
116   ~0u,  // no _oneof_case_
117   ~0u,  // no _weak_field_map_
118   ~0u,  // no _inlined_string_donated_
119   PROTOBUF_FIELD_OFFSET(::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorRequest, _impl_.file_to_generate_),
120   PROTOBUF_FIELD_OFFSET(::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorRequest, _impl_.parameter_),
121   PROTOBUF_FIELD_OFFSET(::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorRequest, _impl_.proto_file_),
122   PROTOBUF_FIELD_OFFSET(::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorRequest, _impl_.compiler_version_),
123   ~0u,
124   0,
125   ~0u,
126   1,
127   PROTOBUF_FIELD_OFFSET(::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorResponse_File, _impl_._has_bits_),
128   PROTOBUF_FIELD_OFFSET(::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorResponse_File, _internal_metadata_),
129   ~0u,  // no _extensions_
130   ~0u,  // no _oneof_case_
131   ~0u,  // no _weak_field_map_
132   ~0u,  // no _inlined_string_donated_
133   PROTOBUF_FIELD_OFFSET(::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorResponse_File, _impl_.name_),
134   PROTOBUF_FIELD_OFFSET(::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorResponse_File, _impl_.insertion_point_),
135   PROTOBUF_FIELD_OFFSET(::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorResponse_File, _impl_.content_),
136   PROTOBUF_FIELD_OFFSET(::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorResponse_File, _impl_.generated_code_info_),
137   0,
138   1,
139   2,
140   3,
141   PROTOBUF_FIELD_OFFSET(::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorResponse, _impl_._has_bits_),
142   PROTOBUF_FIELD_OFFSET(::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorResponse, _internal_metadata_),
143   ~0u,  // no _extensions_
144   ~0u,  // no _oneof_case_
145   ~0u,  // no _weak_field_map_
146   ~0u,  // no _inlined_string_donated_
147   PROTOBUF_FIELD_OFFSET(::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorResponse, _impl_.error_),
148   PROTOBUF_FIELD_OFFSET(::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorResponse, _impl_.supported_features_),
149   PROTOBUF_FIELD_OFFSET(::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorResponse, _impl_.file_),
150   0,
151   1,
152   ~0u,
153 };
154 static const ::_pbi::MigrationSchema schemas[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) = {
155   { 0, 10, -1, sizeof(::PROTOBUF_NAMESPACE_ID::compiler::Version)},
156   { 14, 24, -1, sizeof(::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorRequest)},
157   { 28, 38, -1, sizeof(::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorResponse_File)},
158   { 42, 51, -1, sizeof(::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorResponse)},
159 };
160 
161 static const ::_pb::Message* const file_default_instances[] = {
162   &::PROTOBUF_NAMESPACE_ID::compiler::_Version_default_instance_._instance,
163   &::PROTOBUF_NAMESPACE_ID::compiler::_CodeGeneratorRequest_default_instance_._instance,
164   &::PROTOBUF_NAMESPACE_ID::compiler::_CodeGeneratorResponse_File_default_instance_._instance,
165   &::PROTOBUF_NAMESPACE_ID::compiler::_CodeGeneratorResponse_default_instance_._instance,
166 };
167 
168 const char descriptor_table_protodef_google_2fprotobuf_2fcompiler_2fplugin_2eproto[] PROTOBUF_SECTION_VARIABLE(protodesc_cold) =
169   "\n%google/protobuf/compiler/plugin.proto\022"
170   "\030google.protobuf.compiler\032 google/protob"
171   "uf/descriptor.proto\"F\n\007Version\022\r\n\005major\030"
172   "\001 \001(\005\022\r\n\005minor\030\002 \001(\005\022\r\n\005patch\030\003 \001(\005\022\016\n\006s"
173   "uffix\030\004 \001(\t\"\272\001\n\024CodeGeneratorRequest\022\030\n\020"
174   "file_to_generate\030\001 \003(\t\022\021\n\tparameter\030\002 \001("
175   "\t\0228\n\nproto_file\030\017 \003(\0132$.google.protobuf."
176   "FileDescriptorProto\022;\n\020compiler_version\030"
177   "\003 \001(\0132!.google.protobuf.compiler.Version"
178   "\"\301\002\n\025CodeGeneratorResponse\022\r\n\005error\030\001 \001("
179   "\t\022\032\n\022supported_features\030\002 \001(\004\022B\n\004file\030\017 "
180   "\003(\01324.google.protobuf.compiler.CodeGener"
181   "atorResponse.File\032\177\n\004File\022\014\n\004name\030\001 \001(\t\022"
182   "\027\n\017insertion_point\030\002 \001(\t\022\017\n\007content\030\017 \001("
183   "\t\022\?\n\023generated_code_info\030\020 \001(\0132\".google."
184   "protobuf.GeneratedCodeInfo\"8\n\007Feature\022\020\n"
185   "\014FEATURE_NONE\020\000\022\033\n\027FEATURE_PROTO3_OPTION"
186   "AL\020\001BW\n\034com.google.protobuf.compilerB\014Pl"
187   "uginProtosZ)google.golang.org/protobuf/t"
188   "ypes/pluginpb"
189   ;
190 static const ::_pbi::DescriptorTable* const descriptor_table_google_2fprotobuf_2fcompiler_2fplugin_2eproto_deps[1] = {
191   &::descriptor_table_google_2fprotobuf_2fdescriptor_2eproto,
192 };
193 static ::_pbi::once_flag descriptor_table_google_2fprotobuf_2fcompiler_2fplugin_2eproto_once;
194 const ::_pbi::DescriptorTable descriptor_table_google_2fprotobuf_2fcompiler_2fplugin_2eproto = {
195     false, false, 773, descriptor_table_protodef_google_2fprotobuf_2fcompiler_2fplugin_2eproto,
196     "google/protobuf/compiler/plugin.proto",
197     &descriptor_table_google_2fprotobuf_2fcompiler_2fplugin_2eproto_once, descriptor_table_google_2fprotobuf_2fcompiler_2fplugin_2eproto_deps, 1, 4,
198     schemas, file_default_instances, TableStruct_google_2fprotobuf_2fcompiler_2fplugin_2eproto::offsets,
199     file_level_metadata_google_2fprotobuf_2fcompiler_2fplugin_2eproto, file_level_enum_descriptors_google_2fprotobuf_2fcompiler_2fplugin_2eproto,
200     file_level_service_descriptors_google_2fprotobuf_2fcompiler_2fplugin_2eproto,
201 };
descriptor_table_google_2fprotobuf_2fcompiler_2fplugin_2eproto_getter()202 PROTOBUF_ATTRIBUTE_WEAK const ::_pbi::DescriptorTable* descriptor_table_google_2fprotobuf_2fcompiler_2fplugin_2eproto_getter() {
203   return &descriptor_table_google_2fprotobuf_2fcompiler_2fplugin_2eproto;
204 }
205 
206 // Force running AddDescriptors() at dynamic initialization time.
207 PROTOBUF_ATTRIBUTE_INIT_PRIORITY2 static ::_pbi::AddDescriptorsRunner dynamic_init_dummy_google_2fprotobuf_2fcompiler_2fplugin_2eproto(&descriptor_table_google_2fprotobuf_2fcompiler_2fplugin_2eproto);
208 PROTOBUF_NAMESPACE_OPEN
209 namespace compiler {
CodeGeneratorResponse_Feature_descriptor()210 const ::PROTOBUF_NAMESPACE_ID::EnumDescriptor* CodeGeneratorResponse_Feature_descriptor() {
211   ::PROTOBUF_NAMESPACE_ID::internal::AssignDescriptors(&descriptor_table_google_2fprotobuf_2fcompiler_2fplugin_2eproto);
212   return file_level_enum_descriptors_google_2fprotobuf_2fcompiler_2fplugin_2eproto[0];
213 }
CodeGeneratorResponse_Feature_IsValid(int value)214 bool CodeGeneratorResponse_Feature_IsValid(int value) {
215   switch (value) {
216     case 0:
217     case 1:
218       return true;
219     default:
220       return false;
221   }
222 }
223 
224 #if (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
225 constexpr CodeGeneratorResponse_Feature CodeGeneratorResponse::FEATURE_NONE;
226 constexpr CodeGeneratorResponse_Feature CodeGeneratorResponse::FEATURE_PROTO3_OPTIONAL;
227 constexpr CodeGeneratorResponse_Feature CodeGeneratorResponse::Feature_MIN;
228 constexpr CodeGeneratorResponse_Feature CodeGeneratorResponse::Feature_MAX;
229 constexpr int CodeGeneratorResponse::Feature_ARRAYSIZE;
230 #endif  // (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
231 
232 // ===================================================================
233 
234 class Version::_Internal {
235  public:
236   using HasBits = decltype(std::declval<Version>()._impl_._has_bits_);
set_has_major(HasBits * has_bits)237   static void set_has_major(HasBits* has_bits) {
238     (*has_bits)[0] |= 2u;
239   }
set_has_minor(HasBits * has_bits)240   static void set_has_minor(HasBits* has_bits) {
241     (*has_bits)[0] |= 4u;
242   }
set_has_patch(HasBits * has_bits)243   static void set_has_patch(HasBits* has_bits) {
244     (*has_bits)[0] |= 8u;
245   }
set_has_suffix(HasBits * has_bits)246   static void set_has_suffix(HasBits* has_bits) {
247     (*has_bits)[0] |= 1u;
248   }
249 };
250 
Version(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)251 Version::Version(::PROTOBUF_NAMESPACE_ID::Arena* arena,
252                          bool is_message_owned)
253   : ::PROTOBUF_NAMESPACE_ID::Message(arena, is_message_owned) {
254   SharedCtor(arena, is_message_owned);
255   // @@protoc_insertion_point(arena_constructor:google.protobuf.compiler.Version)
256 }
Version(const Version & from)257 Version::Version(const Version& from)
258   : ::PROTOBUF_NAMESPACE_ID::Message() {
259   Version* const _this = this; (void)_this;
260   new (&_impl_) Impl_{
261       decltype(_impl_._has_bits_){from._impl_._has_bits_}
262     , /*decltype(_impl_._cached_size_)*/{}
263     , decltype(_impl_.suffix_){}
264     , decltype(_impl_.major_){}
265     , decltype(_impl_.minor_){}
266     , decltype(_impl_.patch_){}};
267 
268   _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
269   _impl_.suffix_.InitDefault();
270   #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
271     _impl_.suffix_.Set("", GetArenaForAllocation());
272   #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
273   if (from._internal_has_suffix()) {
274     _this->_impl_.suffix_.Set(from._internal_suffix(),
275       _this->GetArenaForAllocation());
276   }
277   ::memcpy(&_impl_.major_, &from._impl_.major_,
278     static_cast<size_t>(reinterpret_cast<char*>(&_impl_.patch_) -
279     reinterpret_cast<char*>(&_impl_.major_)) + sizeof(_impl_.patch_));
280   // @@protoc_insertion_point(copy_constructor:google.protobuf.compiler.Version)
281 }
282 
SharedCtor(::_pb::Arena * arena,bool is_message_owned)283 inline void Version::SharedCtor(
284     ::_pb::Arena* arena, bool is_message_owned) {
285   (void)arena;
286   (void)is_message_owned;
287   new (&_impl_) Impl_{
288       decltype(_impl_._has_bits_){}
289     , /*decltype(_impl_._cached_size_)*/{}
290     , decltype(_impl_.suffix_){}
291     , decltype(_impl_.major_){0}
292     , decltype(_impl_.minor_){0}
293     , decltype(_impl_.patch_){0}
294   };
295   _impl_.suffix_.InitDefault();
296   #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
297     _impl_.suffix_.Set("", GetArenaForAllocation());
298   #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
299 }
300 
~Version()301 Version::~Version() {
302   // @@protoc_insertion_point(destructor:google.protobuf.compiler.Version)
303   if (auto *arena = _internal_metadata_.DeleteReturnArena<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>()) {
304   (void)arena;
305     return;
306   }
307   SharedDtor();
308 }
309 
SharedDtor()310 inline void Version::SharedDtor() {
311   GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
312   _impl_.suffix_.Destroy();
313 }
314 
SetCachedSize(int size) const315 void Version::SetCachedSize(int size) const {
316   _impl_._cached_size_.Set(size);
317 }
318 
Clear()319 void Version::Clear() {
320 // @@protoc_insertion_point(message_clear_start:google.protobuf.compiler.Version)
321   uint32_t cached_has_bits = 0;
322   // Prevent compiler warnings about cached_has_bits being unused
323   (void) cached_has_bits;
324 
325   cached_has_bits = _impl_._has_bits_[0];
326   if (cached_has_bits & 0x00000001u) {
327     _impl_.suffix_.ClearNonDefaultToEmpty();
328   }
329   if (cached_has_bits & 0x0000000eu) {
330     ::memset(&_impl_.major_, 0, static_cast<size_t>(
331         reinterpret_cast<char*>(&_impl_.patch_) -
332         reinterpret_cast<char*>(&_impl_.major_)) + sizeof(_impl_.patch_));
333   }
334   _impl_._has_bits_.Clear();
335   _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
336 }
337 
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)338 const char* Version::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
339 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
340   _Internal::HasBits has_bits{};
341   while (!ctx->Done(&ptr)) {
342     uint32_t tag;
343     ptr = ::_pbi::ReadTag(ptr, &tag);
344     switch (tag >> 3) {
345       // optional int32 major = 1;
346       case 1:
347         if (PROTOBUF_PREDICT_TRUE(static_cast<uint8_t>(tag) == 8)) {
348           _Internal::set_has_major(&has_bits);
349           _impl_.major_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
350           CHK_(ptr);
351         } else
352           goto handle_unusual;
353         continue;
354       // optional int32 minor = 2;
355       case 2:
356         if (PROTOBUF_PREDICT_TRUE(static_cast<uint8_t>(tag) == 16)) {
357           _Internal::set_has_minor(&has_bits);
358           _impl_.minor_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
359           CHK_(ptr);
360         } else
361           goto handle_unusual;
362         continue;
363       // optional int32 patch = 3;
364       case 3:
365         if (PROTOBUF_PREDICT_TRUE(static_cast<uint8_t>(tag) == 24)) {
366           _Internal::set_has_patch(&has_bits);
367           _impl_.patch_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
368           CHK_(ptr);
369         } else
370           goto handle_unusual;
371         continue;
372       // optional string suffix = 4;
373       case 4:
374         if (PROTOBUF_PREDICT_TRUE(static_cast<uint8_t>(tag) == 34)) {
375           auto str = _internal_mutable_suffix();
376           ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx);
377           CHK_(ptr);
378           #ifndef NDEBUG
379           ::_pbi::VerifyUTF8(str, "google.protobuf.compiler.Version.suffix");
380           #endif  // !NDEBUG
381         } else
382           goto handle_unusual;
383         continue;
384       default:
385         goto handle_unusual;
386     }  // switch
387   handle_unusual:
388     if ((tag == 0) || ((tag & 7) == 4)) {
389       CHK_(ptr);
390       ctx->SetLastTag(tag);
391       goto message_done;
392     }
393     ptr = UnknownFieldParse(
394         tag,
395         _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(),
396         ptr, ctx);
397     CHK_(ptr != nullptr);
398   }  // while
399 message_done:
400   _impl_._has_bits_.Or(has_bits);
401   return ptr;
402 failure:
403   ptr = nullptr;
404   goto message_done;
405 #undef CHK_
406 }
407 
_InternalSerialize(uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const408 uint8_t* Version::_InternalSerialize(
409     uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
410   // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.compiler.Version)
411   uint32_t cached_has_bits = 0;
412   (void) cached_has_bits;
413 
414   cached_has_bits = _impl_._has_bits_[0];
415   // optional int32 major = 1;
416   if (cached_has_bits & 0x00000002u) {
417     target = stream->EnsureSpace(target);
418     target = ::_pbi::WireFormatLite::WriteInt32ToArray(1, this->_internal_major(), target);
419   }
420 
421   // optional int32 minor = 2;
422   if (cached_has_bits & 0x00000004u) {
423     target = stream->EnsureSpace(target);
424     target = ::_pbi::WireFormatLite::WriteInt32ToArray(2, this->_internal_minor(), target);
425   }
426 
427   // optional int32 patch = 3;
428   if (cached_has_bits & 0x00000008u) {
429     target = stream->EnsureSpace(target);
430     target = ::_pbi::WireFormatLite::WriteInt32ToArray(3, this->_internal_patch(), target);
431   }
432 
433   // optional string suffix = 4;
434   if (cached_has_bits & 0x00000001u) {
435     ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::VerifyUTF8StringNamedField(
436       this->_internal_suffix().data(), static_cast<int>(this->_internal_suffix().length()),
437       ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SERIALIZE,
438       "google.protobuf.compiler.Version.suffix");
439     target = stream->WriteStringMaybeAliased(
440         4, this->_internal_suffix(), target);
441   }
442 
443   if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
444     target = ::_pbi::WireFormat::InternalSerializeUnknownFieldsToArray(
445         _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance), target, stream);
446   }
447   // @@protoc_insertion_point(serialize_to_array_end:google.protobuf.compiler.Version)
448   return target;
449 }
450 
ByteSizeLong() const451 size_t Version::ByteSizeLong() const {
452 // @@protoc_insertion_point(message_byte_size_start:google.protobuf.compiler.Version)
453   size_t total_size = 0;
454 
455   uint32_t cached_has_bits = 0;
456   // Prevent compiler warnings about cached_has_bits being unused
457   (void) cached_has_bits;
458 
459   cached_has_bits = _impl_._has_bits_[0];
460   if (cached_has_bits & 0x0000000fu) {
461     // optional string suffix = 4;
462     if (cached_has_bits & 0x00000001u) {
463       total_size += 1 +
464         ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
465           this->_internal_suffix());
466     }
467 
468     // optional int32 major = 1;
469     if (cached_has_bits & 0x00000002u) {
470       total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_major());
471     }
472 
473     // optional int32 minor = 2;
474     if (cached_has_bits & 0x00000004u) {
475       total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_minor());
476     }
477 
478     // optional int32 patch = 3;
479     if (cached_has_bits & 0x00000008u) {
480       total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_patch());
481     }
482 
483   }
484   return MaybeComputeUnknownFieldsSize(total_size, &_impl_._cached_size_);
485 }
486 
487 const ::PROTOBUF_NAMESPACE_ID::Message::ClassData Version::_class_data_ = {
488     ::PROTOBUF_NAMESPACE_ID::Message::CopyWithSourceCheck,
489     Version::MergeImpl
490 };
GetClassData() const491 const ::PROTOBUF_NAMESPACE_ID::Message::ClassData*Version::GetClassData() const { return &_class_data_; }
492 
493 
MergeImpl(::PROTOBUF_NAMESPACE_ID::Message & to_msg,const::PROTOBUF_NAMESPACE_ID::Message & from_msg)494 void Version::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message& to_msg, const ::PROTOBUF_NAMESPACE_ID::Message& from_msg) {
495   auto* const _this = static_cast<Version*>(&to_msg);
496   auto& from = static_cast<const Version&>(from_msg);
497   // @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.compiler.Version)
498   GOOGLE_DCHECK_NE(&from, _this);
499   uint32_t cached_has_bits = 0;
500   (void) cached_has_bits;
501 
502   cached_has_bits = from._impl_._has_bits_[0];
503   if (cached_has_bits & 0x0000000fu) {
504     if (cached_has_bits & 0x00000001u) {
505       _this->_internal_set_suffix(from._internal_suffix());
506     }
507     if (cached_has_bits & 0x00000002u) {
508       _this->_impl_.major_ = from._impl_.major_;
509     }
510     if (cached_has_bits & 0x00000004u) {
511       _this->_impl_.minor_ = from._impl_.minor_;
512     }
513     if (cached_has_bits & 0x00000008u) {
514       _this->_impl_.patch_ = from._impl_.patch_;
515     }
516     _this->_impl_._has_bits_[0] |= cached_has_bits;
517   }
518   _this->_internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
519 }
520 
CopyFrom(const Version & from)521 void Version::CopyFrom(const Version& from) {
522 // @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.compiler.Version)
523   if (&from == this) return;
524   Clear();
525   MergeFrom(from);
526 }
527 
IsInitialized() const528 bool Version::IsInitialized() const {
529   return true;
530 }
531 
InternalSwap(Version * other)532 void Version::InternalSwap(Version* other) {
533   using std::swap;
534   auto* lhs_arena = GetArenaForAllocation();
535   auto* rhs_arena = other->GetArenaForAllocation();
536   _internal_metadata_.InternalSwap(&other->_internal_metadata_);
537   swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
538   ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap(
539       &_impl_.suffix_, lhs_arena,
540       &other->_impl_.suffix_, rhs_arena
541   );
542   ::PROTOBUF_NAMESPACE_ID::internal::memswap<
543       PROTOBUF_FIELD_OFFSET(Version, _impl_.patch_)
544       + sizeof(Version::_impl_.patch_)
545       - PROTOBUF_FIELD_OFFSET(Version, _impl_.major_)>(
546           reinterpret_cast<char*>(&_impl_.major_),
547           reinterpret_cast<char*>(&other->_impl_.major_));
548 }
549 
GetMetadata() const550 ::PROTOBUF_NAMESPACE_ID::Metadata Version::GetMetadata() const {
551   return ::_pbi::AssignDescriptors(
552       &descriptor_table_google_2fprotobuf_2fcompiler_2fplugin_2eproto_getter, &descriptor_table_google_2fprotobuf_2fcompiler_2fplugin_2eproto_once,
553       file_level_metadata_google_2fprotobuf_2fcompiler_2fplugin_2eproto[0]);
554 }
555 
556 // ===================================================================
557 
558 class CodeGeneratorRequest::_Internal {
559  public:
560   using HasBits = decltype(std::declval<CodeGeneratorRequest>()._impl_._has_bits_);
set_has_parameter(HasBits * has_bits)561   static void set_has_parameter(HasBits* has_bits) {
562     (*has_bits)[0] |= 1u;
563   }
564   static const ::PROTOBUF_NAMESPACE_ID::compiler::Version& compiler_version(const CodeGeneratorRequest* msg);
set_has_compiler_version(HasBits * has_bits)565   static void set_has_compiler_version(HasBits* has_bits) {
566     (*has_bits)[0] |= 2u;
567   }
568 };
569 
570 const ::PROTOBUF_NAMESPACE_ID::compiler::Version&
compiler_version(const CodeGeneratorRequest * msg)571 CodeGeneratorRequest::_Internal::compiler_version(const CodeGeneratorRequest* msg) {
572   return *msg->_impl_.compiler_version_;
573 }
clear_proto_file()574 void CodeGeneratorRequest::clear_proto_file() {
575   _impl_.proto_file_.Clear();
576 }
CodeGeneratorRequest(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)577 CodeGeneratorRequest::CodeGeneratorRequest(::PROTOBUF_NAMESPACE_ID::Arena* arena,
578                          bool is_message_owned)
579   : ::PROTOBUF_NAMESPACE_ID::Message(arena, is_message_owned) {
580   SharedCtor(arena, is_message_owned);
581   // @@protoc_insertion_point(arena_constructor:google.protobuf.compiler.CodeGeneratorRequest)
582 }
CodeGeneratorRequest(const CodeGeneratorRequest & from)583 CodeGeneratorRequest::CodeGeneratorRequest(const CodeGeneratorRequest& from)
584   : ::PROTOBUF_NAMESPACE_ID::Message() {
585   CodeGeneratorRequest* const _this = this; (void)_this;
586   new (&_impl_) Impl_{
587       decltype(_impl_._has_bits_){from._impl_._has_bits_}
588     , /*decltype(_impl_._cached_size_)*/{}
589     , decltype(_impl_.file_to_generate_){from._impl_.file_to_generate_}
590     , decltype(_impl_.proto_file_){from._impl_.proto_file_}
591     , decltype(_impl_.parameter_){}
592     , decltype(_impl_.compiler_version_){nullptr}};
593 
594   _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
595   _impl_.parameter_.InitDefault();
596   #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
597     _impl_.parameter_.Set("", GetArenaForAllocation());
598   #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
599   if (from._internal_has_parameter()) {
600     _this->_impl_.parameter_.Set(from._internal_parameter(),
601       _this->GetArenaForAllocation());
602   }
603   if (from._internal_has_compiler_version()) {
604     _this->_impl_.compiler_version_ = new ::PROTOBUF_NAMESPACE_ID::compiler::Version(*from._impl_.compiler_version_);
605   }
606   // @@protoc_insertion_point(copy_constructor:google.protobuf.compiler.CodeGeneratorRequest)
607 }
608 
SharedCtor(::_pb::Arena * arena,bool is_message_owned)609 inline void CodeGeneratorRequest::SharedCtor(
610     ::_pb::Arena* arena, bool is_message_owned) {
611   (void)arena;
612   (void)is_message_owned;
613   new (&_impl_) Impl_{
614       decltype(_impl_._has_bits_){}
615     , /*decltype(_impl_._cached_size_)*/{}
616     , decltype(_impl_.file_to_generate_){arena}
617     , decltype(_impl_.proto_file_){arena}
618     , decltype(_impl_.parameter_){}
619     , decltype(_impl_.compiler_version_){nullptr}
620   };
621   _impl_.parameter_.InitDefault();
622   #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
623     _impl_.parameter_.Set("", GetArenaForAllocation());
624   #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
625 }
626 
~CodeGeneratorRequest()627 CodeGeneratorRequest::~CodeGeneratorRequest() {
628   // @@protoc_insertion_point(destructor:google.protobuf.compiler.CodeGeneratorRequest)
629   if (auto *arena = _internal_metadata_.DeleteReturnArena<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>()) {
630   (void)arena;
631     return;
632   }
633   SharedDtor();
634 }
635 
SharedDtor()636 inline void CodeGeneratorRequest::SharedDtor() {
637   GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
638   _impl_.file_to_generate_.~RepeatedPtrField();
639   _impl_.proto_file_.~RepeatedPtrField();
640   _impl_.parameter_.Destroy();
641   if (this != internal_default_instance()) delete _impl_.compiler_version_;
642 }
643 
SetCachedSize(int size) const644 void CodeGeneratorRequest::SetCachedSize(int size) const {
645   _impl_._cached_size_.Set(size);
646 }
647 
Clear()648 void CodeGeneratorRequest::Clear() {
649 // @@protoc_insertion_point(message_clear_start:google.protobuf.compiler.CodeGeneratorRequest)
650   uint32_t cached_has_bits = 0;
651   // Prevent compiler warnings about cached_has_bits being unused
652   (void) cached_has_bits;
653 
654   _impl_.file_to_generate_.Clear();
655   _impl_.proto_file_.Clear();
656   cached_has_bits = _impl_._has_bits_[0];
657   if (cached_has_bits & 0x00000003u) {
658     if (cached_has_bits & 0x00000001u) {
659       _impl_.parameter_.ClearNonDefaultToEmpty();
660     }
661     if (cached_has_bits & 0x00000002u) {
662       GOOGLE_DCHECK(_impl_.compiler_version_ != nullptr);
663       _impl_.compiler_version_->Clear();
664     }
665   }
666   _impl_._has_bits_.Clear();
667   _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
668 }
669 
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)670 const char* CodeGeneratorRequest::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
671 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
672   _Internal::HasBits has_bits{};
673   while (!ctx->Done(&ptr)) {
674     uint32_t tag;
675     ptr = ::_pbi::ReadTag(ptr, &tag);
676     switch (tag >> 3) {
677       // repeated string file_to_generate = 1;
678       case 1:
679         if (PROTOBUF_PREDICT_TRUE(static_cast<uint8_t>(tag) == 10)) {
680           ptr -= 1;
681           do {
682             ptr += 1;
683             auto str = _internal_add_file_to_generate();
684             ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx);
685             CHK_(ptr);
686             #ifndef NDEBUG
687             ::_pbi::VerifyUTF8(str, "google.protobuf.compiler.CodeGeneratorRequest.file_to_generate");
688             #endif  // !NDEBUG
689             if (!ctx->DataAvailable(ptr)) break;
690           } while (::PROTOBUF_NAMESPACE_ID::internal::ExpectTag<10>(ptr));
691         } else
692           goto handle_unusual;
693         continue;
694       // optional string parameter = 2;
695       case 2:
696         if (PROTOBUF_PREDICT_TRUE(static_cast<uint8_t>(tag) == 18)) {
697           auto str = _internal_mutable_parameter();
698           ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx);
699           CHK_(ptr);
700           #ifndef NDEBUG
701           ::_pbi::VerifyUTF8(str, "google.protobuf.compiler.CodeGeneratorRequest.parameter");
702           #endif  // !NDEBUG
703         } else
704           goto handle_unusual;
705         continue;
706       // optional .google.protobuf.compiler.Version compiler_version = 3;
707       case 3:
708         if (PROTOBUF_PREDICT_TRUE(static_cast<uint8_t>(tag) == 26)) {
709           ptr = ctx->ParseMessage(_internal_mutable_compiler_version(), ptr);
710           CHK_(ptr);
711         } else
712           goto handle_unusual;
713         continue;
714       // repeated .google.protobuf.FileDescriptorProto proto_file = 15;
715       case 15:
716         if (PROTOBUF_PREDICT_TRUE(static_cast<uint8_t>(tag) == 122)) {
717           ptr -= 1;
718           do {
719             ptr += 1;
720             ptr = ctx->ParseMessage(_internal_add_proto_file(), ptr);
721             CHK_(ptr);
722             if (!ctx->DataAvailable(ptr)) break;
723           } while (::PROTOBUF_NAMESPACE_ID::internal::ExpectTag<122>(ptr));
724         } else
725           goto handle_unusual;
726         continue;
727       default:
728         goto handle_unusual;
729     }  // switch
730   handle_unusual:
731     if ((tag == 0) || ((tag & 7) == 4)) {
732       CHK_(ptr);
733       ctx->SetLastTag(tag);
734       goto message_done;
735     }
736     ptr = UnknownFieldParse(
737         tag,
738         _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(),
739         ptr, ctx);
740     CHK_(ptr != nullptr);
741   }  // while
742 message_done:
743   _impl_._has_bits_.Or(has_bits);
744   return ptr;
745 failure:
746   ptr = nullptr;
747   goto message_done;
748 #undef CHK_
749 }
750 
_InternalSerialize(uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const751 uint8_t* CodeGeneratorRequest::_InternalSerialize(
752     uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
753   // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.compiler.CodeGeneratorRequest)
754   uint32_t cached_has_bits = 0;
755   (void) cached_has_bits;
756 
757   // repeated string file_to_generate = 1;
758   for (int i = 0, n = this->_internal_file_to_generate_size(); i < n; i++) {
759     const auto& s = this->_internal_file_to_generate(i);
760     ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::VerifyUTF8StringNamedField(
761       s.data(), static_cast<int>(s.length()),
762       ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SERIALIZE,
763       "google.protobuf.compiler.CodeGeneratorRequest.file_to_generate");
764     target = stream->WriteString(1, s, target);
765   }
766 
767   cached_has_bits = _impl_._has_bits_[0];
768   // optional string parameter = 2;
769   if (cached_has_bits & 0x00000001u) {
770     ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::VerifyUTF8StringNamedField(
771       this->_internal_parameter().data(), static_cast<int>(this->_internal_parameter().length()),
772       ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SERIALIZE,
773       "google.protobuf.compiler.CodeGeneratorRequest.parameter");
774     target = stream->WriteStringMaybeAliased(
775         2, this->_internal_parameter(), target);
776   }
777 
778   // optional .google.protobuf.compiler.Version compiler_version = 3;
779   if (cached_has_bits & 0x00000002u) {
780     target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
781       InternalWriteMessage(3, _Internal::compiler_version(this),
782         _Internal::compiler_version(this).GetCachedSize(), target, stream);
783   }
784 
785   // repeated .google.protobuf.FileDescriptorProto proto_file = 15;
786   for (unsigned i = 0,
787       n = static_cast<unsigned>(this->_internal_proto_file_size()); i < n; i++) {
788     const auto& repfield = this->_internal_proto_file(i);
789     target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
790         InternalWriteMessage(15, repfield, repfield.GetCachedSize(), target, stream);
791   }
792 
793   if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
794     target = ::_pbi::WireFormat::InternalSerializeUnknownFieldsToArray(
795         _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance), target, stream);
796   }
797   // @@protoc_insertion_point(serialize_to_array_end:google.protobuf.compiler.CodeGeneratorRequest)
798   return target;
799 }
800 
ByteSizeLong() const801 size_t CodeGeneratorRequest::ByteSizeLong() const {
802 // @@protoc_insertion_point(message_byte_size_start:google.protobuf.compiler.CodeGeneratorRequest)
803   size_t total_size = 0;
804 
805   uint32_t cached_has_bits = 0;
806   // Prevent compiler warnings about cached_has_bits being unused
807   (void) cached_has_bits;
808 
809   // repeated string file_to_generate = 1;
810   total_size += 1 *
811       ::PROTOBUF_NAMESPACE_ID::internal::FromIntSize(_impl_.file_to_generate_.size());
812   for (int i = 0, n = _impl_.file_to_generate_.size(); i < n; i++) {
813     total_size += ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
814       _impl_.file_to_generate_.Get(i));
815   }
816 
817   // repeated .google.protobuf.FileDescriptorProto proto_file = 15;
818   total_size += 1UL * this->_internal_proto_file_size();
819   for (const auto& msg : this->_impl_.proto_file_) {
820     total_size +=
821       ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(msg);
822   }
823 
824   cached_has_bits = _impl_._has_bits_[0];
825   if (cached_has_bits & 0x00000003u) {
826     // optional string parameter = 2;
827     if (cached_has_bits & 0x00000001u) {
828       total_size += 1 +
829         ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
830           this->_internal_parameter());
831     }
832 
833     // optional .google.protobuf.compiler.Version compiler_version = 3;
834     if (cached_has_bits & 0x00000002u) {
835       total_size += 1 +
836         ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
837           *_impl_.compiler_version_);
838     }
839 
840   }
841   return MaybeComputeUnknownFieldsSize(total_size, &_impl_._cached_size_);
842 }
843 
844 const ::PROTOBUF_NAMESPACE_ID::Message::ClassData CodeGeneratorRequest::_class_data_ = {
845     ::PROTOBUF_NAMESPACE_ID::Message::CopyWithSourceCheck,
846     CodeGeneratorRequest::MergeImpl
847 };
GetClassData() const848 const ::PROTOBUF_NAMESPACE_ID::Message::ClassData*CodeGeneratorRequest::GetClassData() const { return &_class_data_; }
849 
850 
MergeImpl(::PROTOBUF_NAMESPACE_ID::Message & to_msg,const::PROTOBUF_NAMESPACE_ID::Message & from_msg)851 void CodeGeneratorRequest::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message& to_msg, const ::PROTOBUF_NAMESPACE_ID::Message& from_msg) {
852   auto* const _this = static_cast<CodeGeneratorRequest*>(&to_msg);
853   auto& from = static_cast<const CodeGeneratorRequest&>(from_msg);
854   // @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.compiler.CodeGeneratorRequest)
855   GOOGLE_DCHECK_NE(&from, _this);
856   uint32_t cached_has_bits = 0;
857   (void) cached_has_bits;
858 
859   _this->_impl_.file_to_generate_.MergeFrom(from._impl_.file_to_generate_);
860   _this->_impl_.proto_file_.MergeFrom(from._impl_.proto_file_);
861   cached_has_bits = from._impl_._has_bits_[0];
862   if (cached_has_bits & 0x00000003u) {
863     if (cached_has_bits & 0x00000001u) {
864       _this->_internal_set_parameter(from._internal_parameter());
865     }
866     if (cached_has_bits & 0x00000002u) {
867       _this->_internal_mutable_compiler_version()->::PROTOBUF_NAMESPACE_ID::compiler::Version::MergeFrom(
868           from._internal_compiler_version());
869     }
870   }
871   _this->_internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
872 }
873 
CopyFrom(const CodeGeneratorRequest & from)874 void CodeGeneratorRequest::CopyFrom(const CodeGeneratorRequest& from) {
875 // @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.compiler.CodeGeneratorRequest)
876   if (&from == this) return;
877   Clear();
878   MergeFrom(from);
879 }
880 
IsInitialized() const881 bool CodeGeneratorRequest::IsInitialized() const {
882   if (!::PROTOBUF_NAMESPACE_ID::internal::AllAreInitialized(_impl_.proto_file_))
883     return false;
884   return true;
885 }
886 
InternalSwap(CodeGeneratorRequest * other)887 void CodeGeneratorRequest::InternalSwap(CodeGeneratorRequest* other) {
888   using std::swap;
889   auto* lhs_arena = GetArenaForAllocation();
890   auto* rhs_arena = other->GetArenaForAllocation();
891   _internal_metadata_.InternalSwap(&other->_internal_metadata_);
892   swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
893   _impl_.file_to_generate_.InternalSwap(&other->_impl_.file_to_generate_);
894   _impl_.proto_file_.InternalSwap(&other->_impl_.proto_file_);
895   ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap(
896       &_impl_.parameter_, lhs_arena,
897       &other->_impl_.parameter_, rhs_arena
898   );
899   swap(_impl_.compiler_version_, other->_impl_.compiler_version_);
900 }
901 
GetMetadata() const902 ::PROTOBUF_NAMESPACE_ID::Metadata CodeGeneratorRequest::GetMetadata() const {
903   return ::_pbi::AssignDescriptors(
904       &descriptor_table_google_2fprotobuf_2fcompiler_2fplugin_2eproto_getter, &descriptor_table_google_2fprotobuf_2fcompiler_2fplugin_2eproto_once,
905       file_level_metadata_google_2fprotobuf_2fcompiler_2fplugin_2eproto[1]);
906 }
907 
908 // ===================================================================
909 
910 class CodeGeneratorResponse_File::_Internal {
911  public:
912   using HasBits = decltype(std::declval<CodeGeneratorResponse_File>()._impl_._has_bits_);
set_has_name(HasBits * has_bits)913   static void set_has_name(HasBits* has_bits) {
914     (*has_bits)[0] |= 1u;
915   }
set_has_insertion_point(HasBits * has_bits)916   static void set_has_insertion_point(HasBits* has_bits) {
917     (*has_bits)[0] |= 2u;
918   }
set_has_content(HasBits * has_bits)919   static void set_has_content(HasBits* has_bits) {
920     (*has_bits)[0] |= 4u;
921   }
922   static const ::PROTOBUF_NAMESPACE_ID::GeneratedCodeInfo& generated_code_info(const CodeGeneratorResponse_File* msg);
set_has_generated_code_info(HasBits * has_bits)923   static void set_has_generated_code_info(HasBits* has_bits) {
924     (*has_bits)[0] |= 8u;
925   }
926 };
927 
928 const ::PROTOBUF_NAMESPACE_ID::GeneratedCodeInfo&
generated_code_info(const CodeGeneratorResponse_File * msg)929 CodeGeneratorResponse_File::_Internal::generated_code_info(const CodeGeneratorResponse_File* msg) {
930   return *msg->_impl_.generated_code_info_;
931 }
clear_generated_code_info()932 void CodeGeneratorResponse_File::clear_generated_code_info() {
933   if (_impl_.generated_code_info_ != nullptr) _impl_.generated_code_info_->Clear();
934   _impl_._has_bits_[0] &= ~0x00000008u;
935 }
CodeGeneratorResponse_File(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)936 CodeGeneratorResponse_File::CodeGeneratorResponse_File(::PROTOBUF_NAMESPACE_ID::Arena* arena,
937                          bool is_message_owned)
938   : ::PROTOBUF_NAMESPACE_ID::Message(arena, is_message_owned) {
939   SharedCtor(arena, is_message_owned);
940   // @@protoc_insertion_point(arena_constructor:google.protobuf.compiler.CodeGeneratorResponse.File)
941 }
CodeGeneratorResponse_File(const CodeGeneratorResponse_File & from)942 CodeGeneratorResponse_File::CodeGeneratorResponse_File(const CodeGeneratorResponse_File& from)
943   : ::PROTOBUF_NAMESPACE_ID::Message() {
944   CodeGeneratorResponse_File* const _this = this; (void)_this;
945   new (&_impl_) Impl_{
946       decltype(_impl_._has_bits_){from._impl_._has_bits_}
947     , /*decltype(_impl_._cached_size_)*/{}
948     , decltype(_impl_.name_){}
949     , decltype(_impl_.insertion_point_){}
950     , decltype(_impl_.content_){}
951     , decltype(_impl_.generated_code_info_){nullptr}};
952 
953   _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
954   _impl_.name_.InitDefault();
955   #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
956     _impl_.name_.Set("", GetArenaForAllocation());
957   #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
958   if (from._internal_has_name()) {
959     _this->_impl_.name_.Set(from._internal_name(),
960       _this->GetArenaForAllocation());
961   }
962   _impl_.insertion_point_.InitDefault();
963   #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
964     _impl_.insertion_point_.Set("", GetArenaForAllocation());
965   #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
966   if (from._internal_has_insertion_point()) {
967     _this->_impl_.insertion_point_.Set(from._internal_insertion_point(),
968       _this->GetArenaForAllocation());
969   }
970   _impl_.content_.InitDefault();
971   #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
972     _impl_.content_.Set("", GetArenaForAllocation());
973   #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
974   if (from._internal_has_content()) {
975     _this->_impl_.content_.Set(from._internal_content(),
976       _this->GetArenaForAllocation());
977   }
978   if (from._internal_has_generated_code_info()) {
979     _this->_impl_.generated_code_info_ = new ::PROTOBUF_NAMESPACE_ID::GeneratedCodeInfo(*from._impl_.generated_code_info_);
980   }
981   // @@protoc_insertion_point(copy_constructor:google.protobuf.compiler.CodeGeneratorResponse.File)
982 }
983 
SharedCtor(::_pb::Arena * arena,bool is_message_owned)984 inline void CodeGeneratorResponse_File::SharedCtor(
985     ::_pb::Arena* arena, bool is_message_owned) {
986   (void)arena;
987   (void)is_message_owned;
988   new (&_impl_) Impl_{
989       decltype(_impl_._has_bits_){}
990     , /*decltype(_impl_._cached_size_)*/{}
991     , decltype(_impl_.name_){}
992     , decltype(_impl_.insertion_point_){}
993     , decltype(_impl_.content_){}
994     , decltype(_impl_.generated_code_info_){nullptr}
995   };
996   _impl_.name_.InitDefault();
997   #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
998     _impl_.name_.Set("", GetArenaForAllocation());
999   #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
1000   _impl_.insertion_point_.InitDefault();
1001   #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
1002     _impl_.insertion_point_.Set("", GetArenaForAllocation());
1003   #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
1004   _impl_.content_.InitDefault();
1005   #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
1006     _impl_.content_.Set("", GetArenaForAllocation());
1007   #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
1008 }
1009 
~CodeGeneratorResponse_File()1010 CodeGeneratorResponse_File::~CodeGeneratorResponse_File() {
1011   // @@protoc_insertion_point(destructor:google.protobuf.compiler.CodeGeneratorResponse.File)
1012   if (auto *arena = _internal_metadata_.DeleteReturnArena<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>()) {
1013   (void)arena;
1014     return;
1015   }
1016   SharedDtor();
1017 }
1018 
SharedDtor()1019 inline void CodeGeneratorResponse_File::SharedDtor() {
1020   GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
1021   _impl_.name_.Destroy();
1022   _impl_.insertion_point_.Destroy();
1023   _impl_.content_.Destroy();
1024   if (this != internal_default_instance()) delete _impl_.generated_code_info_;
1025 }
1026 
SetCachedSize(int size) const1027 void CodeGeneratorResponse_File::SetCachedSize(int size) const {
1028   _impl_._cached_size_.Set(size);
1029 }
1030 
Clear()1031 void CodeGeneratorResponse_File::Clear() {
1032 // @@protoc_insertion_point(message_clear_start:google.protobuf.compiler.CodeGeneratorResponse.File)
1033   uint32_t cached_has_bits = 0;
1034   // Prevent compiler warnings about cached_has_bits being unused
1035   (void) cached_has_bits;
1036 
1037   cached_has_bits = _impl_._has_bits_[0];
1038   if (cached_has_bits & 0x0000000fu) {
1039     if (cached_has_bits & 0x00000001u) {
1040       _impl_.name_.ClearNonDefaultToEmpty();
1041     }
1042     if (cached_has_bits & 0x00000002u) {
1043       _impl_.insertion_point_.ClearNonDefaultToEmpty();
1044     }
1045     if (cached_has_bits & 0x00000004u) {
1046       _impl_.content_.ClearNonDefaultToEmpty();
1047     }
1048     if (cached_has_bits & 0x00000008u) {
1049       GOOGLE_DCHECK(_impl_.generated_code_info_ != nullptr);
1050       _impl_.generated_code_info_->Clear();
1051     }
1052   }
1053   _impl_._has_bits_.Clear();
1054   _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
1055 }
1056 
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)1057 const char* CodeGeneratorResponse_File::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
1058 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
1059   _Internal::HasBits has_bits{};
1060   while (!ctx->Done(&ptr)) {
1061     uint32_t tag;
1062     ptr = ::_pbi::ReadTag(ptr, &tag);
1063     switch (tag >> 3) {
1064       // optional string name = 1;
1065       case 1:
1066         if (PROTOBUF_PREDICT_TRUE(static_cast<uint8_t>(tag) == 10)) {
1067           auto str = _internal_mutable_name();
1068           ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx);
1069           CHK_(ptr);
1070           #ifndef NDEBUG
1071           ::_pbi::VerifyUTF8(str, "google.protobuf.compiler.CodeGeneratorResponse.File.name");
1072           #endif  // !NDEBUG
1073         } else
1074           goto handle_unusual;
1075         continue;
1076       // optional string insertion_point = 2;
1077       case 2:
1078         if (PROTOBUF_PREDICT_TRUE(static_cast<uint8_t>(tag) == 18)) {
1079           auto str = _internal_mutable_insertion_point();
1080           ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx);
1081           CHK_(ptr);
1082           #ifndef NDEBUG
1083           ::_pbi::VerifyUTF8(str, "google.protobuf.compiler.CodeGeneratorResponse.File.insertion_point");
1084           #endif  // !NDEBUG
1085         } else
1086           goto handle_unusual;
1087         continue;
1088       // optional string content = 15;
1089       case 15:
1090         if (PROTOBUF_PREDICT_TRUE(static_cast<uint8_t>(tag) == 122)) {
1091           auto str = _internal_mutable_content();
1092           ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx);
1093           CHK_(ptr);
1094           #ifndef NDEBUG
1095           ::_pbi::VerifyUTF8(str, "google.protobuf.compiler.CodeGeneratorResponse.File.content");
1096           #endif  // !NDEBUG
1097         } else
1098           goto handle_unusual;
1099         continue;
1100       // optional .google.protobuf.GeneratedCodeInfo generated_code_info = 16;
1101       case 16:
1102         if (PROTOBUF_PREDICT_TRUE(static_cast<uint8_t>(tag) == 130)) {
1103           ptr = ctx->ParseMessage(_internal_mutable_generated_code_info(), ptr);
1104           CHK_(ptr);
1105         } else
1106           goto handle_unusual;
1107         continue;
1108       default:
1109         goto handle_unusual;
1110     }  // switch
1111   handle_unusual:
1112     if ((tag == 0) || ((tag & 7) == 4)) {
1113       CHK_(ptr);
1114       ctx->SetLastTag(tag);
1115       goto message_done;
1116     }
1117     ptr = UnknownFieldParse(
1118         tag,
1119         _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(),
1120         ptr, ctx);
1121     CHK_(ptr != nullptr);
1122   }  // while
1123 message_done:
1124   _impl_._has_bits_.Or(has_bits);
1125   return ptr;
1126 failure:
1127   ptr = nullptr;
1128   goto message_done;
1129 #undef CHK_
1130 }
1131 
_InternalSerialize(uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const1132 uint8_t* CodeGeneratorResponse_File::_InternalSerialize(
1133     uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
1134   // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.compiler.CodeGeneratorResponse.File)
1135   uint32_t cached_has_bits = 0;
1136   (void) cached_has_bits;
1137 
1138   cached_has_bits = _impl_._has_bits_[0];
1139   // optional string name = 1;
1140   if (cached_has_bits & 0x00000001u) {
1141     ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::VerifyUTF8StringNamedField(
1142       this->_internal_name().data(), static_cast<int>(this->_internal_name().length()),
1143       ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SERIALIZE,
1144       "google.protobuf.compiler.CodeGeneratorResponse.File.name");
1145     target = stream->WriteStringMaybeAliased(
1146         1, this->_internal_name(), target);
1147   }
1148 
1149   // optional string insertion_point = 2;
1150   if (cached_has_bits & 0x00000002u) {
1151     ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::VerifyUTF8StringNamedField(
1152       this->_internal_insertion_point().data(), static_cast<int>(this->_internal_insertion_point().length()),
1153       ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SERIALIZE,
1154       "google.protobuf.compiler.CodeGeneratorResponse.File.insertion_point");
1155     target = stream->WriteStringMaybeAliased(
1156         2, this->_internal_insertion_point(), target);
1157   }
1158 
1159   // optional string content = 15;
1160   if (cached_has_bits & 0x00000004u) {
1161     ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::VerifyUTF8StringNamedField(
1162       this->_internal_content().data(), static_cast<int>(this->_internal_content().length()),
1163       ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SERIALIZE,
1164       "google.protobuf.compiler.CodeGeneratorResponse.File.content");
1165     target = stream->WriteStringMaybeAliased(
1166         15, this->_internal_content(), target);
1167   }
1168 
1169   // optional .google.protobuf.GeneratedCodeInfo generated_code_info = 16;
1170   if (cached_has_bits & 0x00000008u) {
1171     target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
1172       InternalWriteMessage(16, _Internal::generated_code_info(this),
1173         _Internal::generated_code_info(this).GetCachedSize(), target, stream);
1174   }
1175 
1176   if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
1177     target = ::_pbi::WireFormat::InternalSerializeUnknownFieldsToArray(
1178         _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance), target, stream);
1179   }
1180   // @@protoc_insertion_point(serialize_to_array_end:google.protobuf.compiler.CodeGeneratorResponse.File)
1181   return target;
1182 }
1183 
ByteSizeLong() const1184 size_t CodeGeneratorResponse_File::ByteSizeLong() const {
1185 // @@protoc_insertion_point(message_byte_size_start:google.protobuf.compiler.CodeGeneratorResponse.File)
1186   size_t total_size = 0;
1187 
1188   uint32_t cached_has_bits = 0;
1189   // Prevent compiler warnings about cached_has_bits being unused
1190   (void) cached_has_bits;
1191 
1192   cached_has_bits = _impl_._has_bits_[0];
1193   if (cached_has_bits & 0x0000000fu) {
1194     // optional string name = 1;
1195     if (cached_has_bits & 0x00000001u) {
1196       total_size += 1 +
1197         ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
1198           this->_internal_name());
1199     }
1200 
1201     // optional string insertion_point = 2;
1202     if (cached_has_bits & 0x00000002u) {
1203       total_size += 1 +
1204         ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
1205           this->_internal_insertion_point());
1206     }
1207 
1208     // optional string content = 15;
1209     if (cached_has_bits & 0x00000004u) {
1210       total_size += 1 +
1211         ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
1212           this->_internal_content());
1213     }
1214 
1215     // optional .google.protobuf.GeneratedCodeInfo generated_code_info = 16;
1216     if (cached_has_bits & 0x00000008u) {
1217       total_size += 2 +
1218         ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
1219           *_impl_.generated_code_info_);
1220     }
1221 
1222   }
1223   return MaybeComputeUnknownFieldsSize(total_size, &_impl_._cached_size_);
1224 }
1225 
1226 const ::PROTOBUF_NAMESPACE_ID::Message::ClassData CodeGeneratorResponse_File::_class_data_ = {
1227     ::PROTOBUF_NAMESPACE_ID::Message::CopyWithSourceCheck,
1228     CodeGeneratorResponse_File::MergeImpl
1229 };
GetClassData() const1230 const ::PROTOBUF_NAMESPACE_ID::Message::ClassData*CodeGeneratorResponse_File::GetClassData() const { return &_class_data_; }
1231 
1232 
MergeImpl(::PROTOBUF_NAMESPACE_ID::Message & to_msg,const::PROTOBUF_NAMESPACE_ID::Message & from_msg)1233 void CodeGeneratorResponse_File::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message& to_msg, const ::PROTOBUF_NAMESPACE_ID::Message& from_msg) {
1234   auto* const _this = static_cast<CodeGeneratorResponse_File*>(&to_msg);
1235   auto& from = static_cast<const CodeGeneratorResponse_File&>(from_msg);
1236   // @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.compiler.CodeGeneratorResponse.File)
1237   GOOGLE_DCHECK_NE(&from, _this);
1238   uint32_t cached_has_bits = 0;
1239   (void) cached_has_bits;
1240 
1241   cached_has_bits = from._impl_._has_bits_[0];
1242   if (cached_has_bits & 0x0000000fu) {
1243     if (cached_has_bits & 0x00000001u) {
1244       _this->_internal_set_name(from._internal_name());
1245     }
1246     if (cached_has_bits & 0x00000002u) {
1247       _this->_internal_set_insertion_point(from._internal_insertion_point());
1248     }
1249     if (cached_has_bits & 0x00000004u) {
1250       _this->_internal_set_content(from._internal_content());
1251     }
1252     if (cached_has_bits & 0x00000008u) {
1253       _this->_internal_mutable_generated_code_info()->::PROTOBUF_NAMESPACE_ID::GeneratedCodeInfo::MergeFrom(
1254           from._internal_generated_code_info());
1255     }
1256   }
1257   _this->_internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
1258 }
1259 
CopyFrom(const CodeGeneratorResponse_File & from)1260 void CodeGeneratorResponse_File::CopyFrom(const CodeGeneratorResponse_File& from) {
1261 // @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.compiler.CodeGeneratorResponse.File)
1262   if (&from == this) return;
1263   Clear();
1264   MergeFrom(from);
1265 }
1266 
IsInitialized() const1267 bool CodeGeneratorResponse_File::IsInitialized() const {
1268   return true;
1269 }
1270 
InternalSwap(CodeGeneratorResponse_File * other)1271 void CodeGeneratorResponse_File::InternalSwap(CodeGeneratorResponse_File* other) {
1272   using std::swap;
1273   auto* lhs_arena = GetArenaForAllocation();
1274   auto* rhs_arena = other->GetArenaForAllocation();
1275   _internal_metadata_.InternalSwap(&other->_internal_metadata_);
1276   swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
1277   ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap(
1278       &_impl_.name_, lhs_arena,
1279       &other->_impl_.name_, rhs_arena
1280   );
1281   ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap(
1282       &_impl_.insertion_point_, lhs_arena,
1283       &other->_impl_.insertion_point_, rhs_arena
1284   );
1285   ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap(
1286       &_impl_.content_, lhs_arena,
1287       &other->_impl_.content_, rhs_arena
1288   );
1289   swap(_impl_.generated_code_info_, other->_impl_.generated_code_info_);
1290 }
1291 
GetMetadata() const1292 ::PROTOBUF_NAMESPACE_ID::Metadata CodeGeneratorResponse_File::GetMetadata() const {
1293   return ::_pbi::AssignDescriptors(
1294       &descriptor_table_google_2fprotobuf_2fcompiler_2fplugin_2eproto_getter, &descriptor_table_google_2fprotobuf_2fcompiler_2fplugin_2eproto_once,
1295       file_level_metadata_google_2fprotobuf_2fcompiler_2fplugin_2eproto[2]);
1296 }
1297 
1298 // ===================================================================
1299 
1300 class CodeGeneratorResponse::_Internal {
1301  public:
1302   using HasBits = decltype(std::declval<CodeGeneratorResponse>()._impl_._has_bits_);
set_has_error(HasBits * has_bits)1303   static void set_has_error(HasBits* has_bits) {
1304     (*has_bits)[0] |= 1u;
1305   }
set_has_supported_features(HasBits * has_bits)1306   static void set_has_supported_features(HasBits* has_bits) {
1307     (*has_bits)[0] |= 2u;
1308   }
1309 };
1310 
CodeGeneratorResponse(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)1311 CodeGeneratorResponse::CodeGeneratorResponse(::PROTOBUF_NAMESPACE_ID::Arena* arena,
1312                          bool is_message_owned)
1313   : ::PROTOBUF_NAMESPACE_ID::Message(arena, is_message_owned) {
1314   SharedCtor(arena, is_message_owned);
1315   // @@protoc_insertion_point(arena_constructor:google.protobuf.compiler.CodeGeneratorResponse)
1316 }
CodeGeneratorResponse(const CodeGeneratorResponse & from)1317 CodeGeneratorResponse::CodeGeneratorResponse(const CodeGeneratorResponse& from)
1318   : ::PROTOBUF_NAMESPACE_ID::Message() {
1319   CodeGeneratorResponse* const _this = this; (void)_this;
1320   new (&_impl_) Impl_{
1321       decltype(_impl_._has_bits_){from._impl_._has_bits_}
1322     , /*decltype(_impl_._cached_size_)*/{}
1323     , decltype(_impl_.file_){from._impl_.file_}
1324     , decltype(_impl_.error_){}
1325     , decltype(_impl_.supported_features_){}};
1326 
1327   _internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
1328   _impl_.error_.InitDefault();
1329   #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
1330     _impl_.error_.Set("", GetArenaForAllocation());
1331   #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
1332   if (from._internal_has_error()) {
1333     _this->_impl_.error_.Set(from._internal_error(),
1334       _this->GetArenaForAllocation());
1335   }
1336   _this->_impl_.supported_features_ = from._impl_.supported_features_;
1337   // @@protoc_insertion_point(copy_constructor:google.protobuf.compiler.CodeGeneratorResponse)
1338 }
1339 
SharedCtor(::_pb::Arena * arena,bool is_message_owned)1340 inline void CodeGeneratorResponse::SharedCtor(
1341     ::_pb::Arena* arena, bool is_message_owned) {
1342   (void)arena;
1343   (void)is_message_owned;
1344   new (&_impl_) Impl_{
1345       decltype(_impl_._has_bits_){}
1346     , /*decltype(_impl_._cached_size_)*/{}
1347     , decltype(_impl_.file_){arena}
1348     , decltype(_impl_.error_){}
1349     , decltype(_impl_.supported_features_){uint64_t{0u}}
1350   };
1351   _impl_.error_.InitDefault();
1352   #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
1353     _impl_.error_.Set("", GetArenaForAllocation());
1354   #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
1355 }
1356 
~CodeGeneratorResponse()1357 CodeGeneratorResponse::~CodeGeneratorResponse() {
1358   // @@protoc_insertion_point(destructor:google.protobuf.compiler.CodeGeneratorResponse)
1359   if (auto *arena = _internal_metadata_.DeleteReturnArena<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>()) {
1360   (void)arena;
1361     return;
1362   }
1363   SharedDtor();
1364 }
1365 
SharedDtor()1366 inline void CodeGeneratorResponse::SharedDtor() {
1367   GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
1368   _impl_.file_.~RepeatedPtrField();
1369   _impl_.error_.Destroy();
1370 }
1371 
SetCachedSize(int size) const1372 void CodeGeneratorResponse::SetCachedSize(int size) const {
1373   _impl_._cached_size_.Set(size);
1374 }
1375 
Clear()1376 void CodeGeneratorResponse::Clear() {
1377 // @@protoc_insertion_point(message_clear_start:google.protobuf.compiler.CodeGeneratorResponse)
1378   uint32_t cached_has_bits = 0;
1379   // Prevent compiler warnings about cached_has_bits being unused
1380   (void) cached_has_bits;
1381 
1382   _impl_.file_.Clear();
1383   cached_has_bits = _impl_._has_bits_[0];
1384   if (cached_has_bits & 0x00000001u) {
1385     _impl_.error_.ClearNonDefaultToEmpty();
1386   }
1387   _impl_.supported_features_ = uint64_t{0u};
1388   _impl_._has_bits_.Clear();
1389   _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>();
1390 }
1391 
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)1392 const char* CodeGeneratorResponse::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
1393 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
1394   _Internal::HasBits has_bits{};
1395   while (!ctx->Done(&ptr)) {
1396     uint32_t tag;
1397     ptr = ::_pbi::ReadTag(ptr, &tag);
1398     switch (tag >> 3) {
1399       // optional string error = 1;
1400       case 1:
1401         if (PROTOBUF_PREDICT_TRUE(static_cast<uint8_t>(tag) == 10)) {
1402           auto str = _internal_mutable_error();
1403           ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx);
1404           CHK_(ptr);
1405           #ifndef NDEBUG
1406           ::_pbi::VerifyUTF8(str, "google.protobuf.compiler.CodeGeneratorResponse.error");
1407           #endif  // !NDEBUG
1408         } else
1409           goto handle_unusual;
1410         continue;
1411       // optional uint64 supported_features = 2;
1412       case 2:
1413         if (PROTOBUF_PREDICT_TRUE(static_cast<uint8_t>(tag) == 16)) {
1414           _Internal::set_has_supported_features(&has_bits);
1415           _impl_.supported_features_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
1416           CHK_(ptr);
1417         } else
1418           goto handle_unusual;
1419         continue;
1420       // repeated .google.protobuf.compiler.CodeGeneratorResponse.File file = 15;
1421       case 15:
1422         if (PROTOBUF_PREDICT_TRUE(static_cast<uint8_t>(tag) == 122)) {
1423           ptr -= 1;
1424           do {
1425             ptr += 1;
1426             ptr = ctx->ParseMessage(_internal_add_file(), ptr);
1427             CHK_(ptr);
1428             if (!ctx->DataAvailable(ptr)) break;
1429           } while (::PROTOBUF_NAMESPACE_ID::internal::ExpectTag<122>(ptr));
1430         } else
1431           goto handle_unusual;
1432         continue;
1433       default:
1434         goto handle_unusual;
1435     }  // switch
1436   handle_unusual:
1437     if ((tag == 0) || ((tag & 7) == 4)) {
1438       CHK_(ptr);
1439       ctx->SetLastTag(tag);
1440       goto message_done;
1441     }
1442     ptr = UnknownFieldParse(
1443         tag,
1444         _internal_metadata_.mutable_unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(),
1445         ptr, ctx);
1446     CHK_(ptr != nullptr);
1447   }  // while
1448 message_done:
1449   _impl_._has_bits_.Or(has_bits);
1450   return ptr;
1451 failure:
1452   ptr = nullptr;
1453   goto message_done;
1454 #undef CHK_
1455 }
1456 
_InternalSerialize(uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const1457 uint8_t* CodeGeneratorResponse::_InternalSerialize(
1458     uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
1459   // @@protoc_insertion_point(serialize_to_array_start:google.protobuf.compiler.CodeGeneratorResponse)
1460   uint32_t cached_has_bits = 0;
1461   (void) cached_has_bits;
1462 
1463   cached_has_bits = _impl_._has_bits_[0];
1464   // optional string error = 1;
1465   if (cached_has_bits & 0x00000001u) {
1466     ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::VerifyUTF8StringNamedField(
1467       this->_internal_error().data(), static_cast<int>(this->_internal_error().length()),
1468       ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::SERIALIZE,
1469       "google.protobuf.compiler.CodeGeneratorResponse.error");
1470     target = stream->WriteStringMaybeAliased(
1471         1, this->_internal_error(), target);
1472   }
1473 
1474   // optional uint64 supported_features = 2;
1475   if (cached_has_bits & 0x00000002u) {
1476     target = stream->EnsureSpace(target);
1477     target = ::_pbi::WireFormatLite::WriteUInt64ToArray(2, this->_internal_supported_features(), target);
1478   }
1479 
1480   // repeated .google.protobuf.compiler.CodeGeneratorResponse.File file = 15;
1481   for (unsigned i = 0,
1482       n = static_cast<unsigned>(this->_internal_file_size()); i < n; i++) {
1483     const auto& repfield = this->_internal_file(i);
1484     target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
1485         InternalWriteMessage(15, repfield, repfield.GetCachedSize(), target, stream);
1486   }
1487 
1488   if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
1489     target = ::_pbi::WireFormat::InternalSerializeUnknownFieldsToArray(
1490         _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance), target, stream);
1491   }
1492   // @@protoc_insertion_point(serialize_to_array_end:google.protobuf.compiler.CodeGeneratorResponse)
1493   return target;
1494 }
1495 
ByteSizeLong() const1496 size_t CodeGeneratorResponse::ByteSizeLong() const {
1497 // @@protoc_insertion_point(message_byte_size_start:google.protobuf.compiler.CodeGeneratorResponse)
1498   size_t total_size = 0;
1499 
1500   uint32_t cached_has_bits = 0;
1501   // Prevent compiler warnings about cached_has_bits being unused
1502   (void) cached_has_bits;
1503 
1504   // repeated .google.protobuf.compiler.CodeGeneratorResponse.File file = 15;
1505   total_size += 1UL * this->_internal_file_size();
1506   for (const auto& msg : this->_impl_.file_) {
1507     total_size +=
1508       ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(msg);
1509   }
1510 
1511   cached_has_bits = _impl_._has_bits_[0];
1512   if (cached_has_bits & 0x00000003u) {
1513     // optional string error = 1;
1514     if (cached_has_bits & 0x00000001u) {
1515       total_size += 1 +
1516         ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
1517           this->_internal_error());
1518     }
1519 
1520     // optional uint64 supported_features = 2;
1521     if (cached_has_bits & 0x00000002u) {
1522       total_size += ::_pbi::WireFormatLite::UInt64SizePlusOne(this->_internal_supported_features());
1523     }
1524 
1525   }
1526   return MaybeComputeUnknownFieldsSize(total_size, &_impl_._cached_size_);
1527 }
1528 
1529 const ::PROTOBUF_NAMESPACE_ID::Message::ClassData CodeGeneratorResponse::_class_data_ = {
1530     ::PROTOBUF_NAMESPACE_ID::Message::CopyWithSourceCheck,
1531     CodeGeneratorResponse::MergeImpl
1532 };
GetClassData() const1533 const ::PROTOBUF_NAMESPACE_ID::Message::ClassData*CodeGeneratorResponse::GetClassData() const { return &_class_data_; }
1534 
1535 
MergeImpl(::PROTOBUF_NAMESPACE_ID::Message & to_msg,const::PROTOBUF_NAMESPACE_ID::Message & from_msg)1536 void CodeGeneratorResponse::MergeImpl(::PROTOBUF_NAMESPACE_ID::Message& to_msg, const ::PROTOBUF_NAMESPACE_ID::Message& from_msg) {
1537   auto* const _this = static_cast<CodeGeneratorResponse*>(&to_msg);
1538   auto& from = static_cast<const CodeGeneratorResponse&>(from_msg);
1539   // @@protoc_insertion_point(class_specific_merge_from_start:google.protobuf.compiler.CodeGeneratorResponse)
1540   GOOGLE_DCHECK_NE(&from, _this);
1541   uint32_t cached_has_bits = 0;
1542   (void) cached_has_bits;
1543 
1544   _this->_impl_.file_.MergeFrom(from._impl_.file_);
1545   cached_has_bits = from._impl_._has_bits_[0];
1546   if (cached_has_bits & 0x00000003u) {
1547     if (cached_has_bits & 0x00000001u) {
1548       _this->_internal_set_error(from._internal_error());
1549     }
1550     if (cached_has_bits & 0x00000002u) {
1551       _this->_impl_.supported_features_ = from._impl_.supported_features_;
1552     }
1553     _this->_impl_._has_bits_[0] |= cached_has_bits;
1554   }
1555   _this->_internal_metadata_.MergeFrom<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(from._internal_metadata_);
1556 }
1557 
CopyFrom(const CodeGeneratorResponse & from)1558 void CodeGeneratorResponse::CopyFrom(const CodeGeneratorResponse& from) {
1559 // @@protoc_insertion_point(class_specific_copy_from_start:google.protobuf.compiler.CodeGeneratorResponse)
1560   if (&from == this) return;
1561   Clear();
1562   MergeFrom(from);
1563 }
1564 
IsInitialized() const1565 bool CodeGeneratorResponse::IsInitialized() const {
1566   return true;
1567 }
1568 
InternalSwap(CodeGeneratorResponse * other)1569 void CodeGeneratorResponse::InternalSwap(CodeGeneratorResponse* other) {
1570   using std::swap;
1571   auto* lhs_arena = GetArenaForAllocation();
1572   auto* rhs_arena = other->GetArenaForAllocation();
1573   _internal_metadata_.InternalSwap(&other->_internal_metadata_);
1574   swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
1575   _impl_.file_.InternalSwap(&other->_impl_.file_);
1576   ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap(
1577       &_impl_.error_, lhs_arena,
1578       &other->_impl_.error_, rhs_arena
1579   );
1580   swap(_impl_.supported_features_, other->_impl_.supported_features_);
1581 }
1582 
GetMetadata() const1583 ::PROTOBUF_NAMESPACE_ID::Metadata CodeGeneratorResponse::GetMetadata() const {
1584   return ::_pbi::AssignDescriptors(
1585       &descriptor_table_google_2fprotobuf_2fcompiler_2fplugin_2eproto_getter, &descriptor_table_google_2fprotobuf_2fcompiler_2fplugin_2eproto_once,
1586       file_level_metadata_google_2fprotobuf_2fcompiler_2fplugin_2eproto[3]);
1587 }
1588 
1589 // @@protoc_insertion_point(namespace_scope)
1590 }  // namespace compiler
1591 PROTOBUF_NAMESPACE_CLOSE
1592 PROTOBUF_NAMESPACE_OPEN
1593 template<> PROTOBUF_NOINLINE ::PROTOBUF_NAMESPACE_ID::compiler::Version*
CreateMaybeMessage(Arena * arena)1594 Arena::CreateMaybeMessage< ::PROTOBUF_NAMESPACE_ID::compiler::Version >(Arena* arena) {
1595   return Arena::CreateMessageInternal< ::PROTOBUF_NAMESPACE_ID::compiler::Version >(arena);
1596 }
1597 template<> PROTOBUF_NOINLINE ::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorRequest*
CreateMaybeMessage(Arena * arena)1598 Arena::CreateMaybeMessage< ::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorRequest >(Arena* arena) {
1599   return Arena::CreateMessageInternal< ::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorRequest >(arena);
1600 }
1601 template<> PROTOBUF_NOINLINE ::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorResponse_File*
CreateMaybeMessage(Arena * arena)1602 Arena::CreateMaybeMessage< ::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorResponse_File >(Arena* arena) {
1603   return Arena::CreateMessageInternal< ::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorResponse_File >(arena);
1604 }
1605 template<> PROTOBUF_NOINLINE ::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorResponse*
CreateMaybeMessage(Arena * arena)1606 Arena::CreateMaybeMessage< ::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorResponse >(Arena* arena) {
1607   return Arena::CreateMessageInternal< ::PROTOBUF_NAMESPACE_ID::compiler::CodeGeneratorResponse >(arena);
1608 }
1609 PROTOBUF_NAMESPACE_CLOSE
1610 
1611 // @@protoc_insertion_point(global_scope)
1612 #include <google/protobuf/port_undef.inc>
1613