Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

internal/cmd/generate-alias: fix generator for lacking go_package options #1061

Merged
merged 1 commit into from Mar 20, 2020

Conversation

dsnet
Copy link
Member

@dsnet dsnet commented Mar 20, 2020

In https://golang.org/cl/219598, we removed patching the well-known types
with an explicit go_package option and instead relied on M flags.
The lack of updated go_package options broke generate-alias since it
appears as if the import public is trying to alias Go identifiers
within the same Go package (thus generating nothing).

We fix generate-alias by replicating the same approach here,
where we construct the M flag mapping and pass it to protoc-gen-go.

…ions

In https://golang.org/cl/219598, we removed patching the well-known types
with an explicit go_package option and instead relied on M flags.
The lack of updated go_package options broke generate-alias since it
appears as if the import public is trying to alias Go identifiers
within the same Go package (thus generating nothing).

We fix generate-alias by replicating the same approach here,
where we construct the M flag mapping and pass it to protoc-gen-go.
@dsnet dsnet merged commit 7592abe into api-v1 Mar 20, 2020
@dsnet dsnet deleted the gen-alias branch March 20, 2020 21:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants