-
Notifications
You must be signed in to change notification settings - Fork 148
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
Using standard way for specifying proto field options #40
Comments
Not for now, although I would be happy to accept a PR. |
Thanks 👍🏽 Help wanted, otherwise might take a look at some point 🤗 |
Looking at the options/extensions functionality in proto3, I'm not sure if it would be a good fit for this kind of logic (actually I do think it is, but more details below... 😄). The E.g: [...]
import "google/protobuf/descriptor.proto";
extend google.protobuf.FieldOptions {
string gotags = 50001;
}
message IP {
string Address = 1 [(gotags) = "this is a test"]; // "this is a test" doesn't show up in test.pb.go, other than maybe the byte array of the wire-formatted description.
} (see also: this must be a non-popular feature that is used, since Github and VSCode's syntax highlighting hates this, but it's valid and compiles!) The main problem with where it's stored, is that we'd have to figure out how to map the raw data from the wire format doc, and map it on top of what The ideal location of this logic is within Skimming through the rest of the spec, I don't see anything that could be used (or abused) for this functionality, other than comments like this tool is currently doing. Any other thoughts? Could I be missing something? |
Hi,
Is there a way to use this awesome tool but std using field options. The problem is when we have many other options if every plugin has a different way of specifying this, it just gets confusing 🤔
What I mean:
The text was updated successfully, but these errors were encountered: