Skip to content

Commit

Permalink
Merge pull request #53 from AndrewBase/master
Browse files Browse the repository at this point in the history
Support proto editions
  • Loading branch information
mescanne authored Dec 12, 2024
2 parents 65c3ebd + 090e6c5 commit 5c940a6
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pkg/converter/convert.go
Original file line number Diff line number Diff line change
Expand Up @@ -408,7 +408,9 @@ func Convert(req *plugin.CodeGeneratorRequest) (*plugin.CodeGeneratorResponse, e
}

res := &plugin.CodeGeneratorResponse{
SupportedFeatures: proto.Uint64(uint64(plugin.CodeGeneratorResponse_FEATURE_PROTO3_OPTIONAL)),
SupportedFeatures: proto.Uint64(uint64(plugin.CodeGeneratorResponse_FEATURE_PROTO3_OPTIONAL | plugin.CodeGeneratorResponse_FEATURE_SUPPORTS_EDITIONS)),
MinimumEdition: proto.Int32(int32(descriptor.Edition_EDITION_PROTO2)),
MaximumEdition: proto.Int32(int32(descriptor.Edition_EDITION_MAX)),
}
for _, file := range req.GetProtoFile() {
for msgIndex, msg := range file.GetMessageType() {
Expand Down

0 comments on commit 5c940a6

Please sign in to comment.