mirror of
https://github.com/ceph/ceph-csi.git
synced 2025-06-14 10:53:34 +00:00
rebase: bump google.golang.org/protobuf from 1.33.0 to 1.34.1
Bumps google.golang.org/protobuf from 1.33.0 to 1.34.1. --- updated-dependencies: - dependency-name: google.golang.org/protobuf dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
This commit is contained in:
committed by
mergify[bot]
parent
84308d0ddb
commit
86bc40fbff
22
vendor/google.golang.org/protobuf/reflect/protodesc/proto.go
generated
vendored
22
vendor/google.golang.org/protobuf/reflect/protodesc/proto.go
generated
vendored
@ -73,6 +73,16 @@ func ToFileDescriptorProto(file protoreflect.FileDescriptor) *descriptorpb.FileD
|
||||
if syntax := file.Syntax(); syntax != protoreflect.Proto2 && syntax.IsValid() {
|
||||
p.Syntax = proto.String(file.Syntax().String())
|
||||
}
|
||||
if file.Syntax() == protoreflect.Editions {
|
||||
desc := file
|
||||
if fileImportDesc, ok := file.(protoreflect.FileImport); ok {
|
||||
desc = fileImportDesc.FileDescriptor
|
||||
}
|
||||
|
||||
if editionsInterface, ok := desc.(interface{ Edition() int32 }); ok {
|
||||
p.Edition = descriptorpb.Edition(editionsInterface.Edition()).Enum()
|
||||
}
|
||||
}
|
||||
return p
|
||||
}
|
||||
|
||||
@ -153,6 +163,18 @@ func ToFieldDescriptorProto(field protoreflect.FieldDescriptor) *descriptorpb.Fi
|
||||
if field.Syntax() == protoreflect.Proto3 && field.HasOptionalKeyword() {
|
||||
p.Proto3Optional = proto.Bool(true)
|
||||
}
|
||||
if field.Syntax() == protoreflect.Editions {
|
||||
// Editions have no group keyword, this type is only set so that downstream users continue
|
||||
// treating this as delimited encoding.
|
||||
if p.GetType() == descriptorpb.FieldDescriptorProto_TYPE_GROUP {
|
||||
p.Type = descriptorpb.FieldDescriptorProto_TYPE_MESSAGE.Enum()
|
||||
}
|
||||
// Editions have no required keyword, this label is only set so that downstream users continue
|
||||
// treating it as required.
|
||||
if p.GetLabel() == descriptorpb.FieldDescriptorProto_LABEL_REQUIRED {
|
||||
p.Label = descriptorpb.FieldDescriptorProto_LABEL_OPTIONAL.Enum()
|
||||
}
|
||||
}
|
||||
if field.HasDefault() {
|
||||
def, err := defval.Marshal(field.Default(), field.DefaultEnumValue(), field.Kind(), defval.Descriptor)
|
||||
if err != nil && field.DefaultEnumValue() != nil {
|
||||
|
Reference in New Issue
Block a user