Skip to content

Commit

Permalink
protoc-gen-go: generate XXX_OneofWrappers instead of XXX_OneofFuncs (#…
Browse files Browse the repository at this point in the history
…760)

The marshaler, unmarshaler, and sizer functions are unused ever since
the underlying implementation was switched to be table-driven.
Change the function to only return the wrapper structs.

This change:
* enables generated protos to drop dependencies on certain proto types
* reduces the size of generated protos
* simplifies the implementation of oneofs in protoc-gen-go

Updates #708
  • Loading branch information
dsnet committed Nov 27, 2018
1 parent 882cf97 commit 8d0c54c
Show file tree
Hide file tree
Showing 42 changed files with 149 additions and 1,707 deletions.
281 changes: 10 additions & 271 deletions conformance/internal/conformance_proto/conformance.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion jsonpb/jsonpb_test_proto/more_test_objects.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 comments on commit 8d0c54c

@mortezaalizadeh
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey guys, is there any plan to release the above changes? cheers

@dsnet
Copy link
Member Author

@dsnet dsnet commented on 8d0c54c Nov 28, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a pressing need for it? There haven’t been that many substantial changes since v1.2 to justify a another release quite yet.

@dsnet
Copy link
Member Author

@dsnet dsnet commented on 8d0c54c Nov 28, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For future visitors coming here due to broken builds. Please read #763 (comment)

Please sign in to comment.