|
|
|
@ -358,11 +358,7 @@ bool HasRequiredFields(const Descriptor* descriptor); |
|
|
|
|
bool IsRealOneof(const FieldDescriptor* descriptor); |
|
|
|
|
|
|
|
|
|
inline bool HasHasbit(const FieldDescriptor* descriptor) { |
|
|
|
|
// TODO(b/241441075) Replace this with internal::cpp::HasHasbit once Elysium
|
|
|
|
|
// unblocks this change.
|
|
|
|
|
return (FieldDescriptorLegacy(descriptor).has_optional_keyword() || |
|
|
|
|
descriptor->is_required()) && |
|
|
|
|
!descriptor->options().weak(); |
|
|
|
|
return internal::cpp::HasHasbit(descriptor); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
// Whether generate classes expose public PARSER instances.
|
|
|
|
|