You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I try to compile the Proto, I get an error along the lines of:
71 | pub fn set_bar(&mut self, v: Bar) {
| ---------------------------------------------------------- other definition for `set_bar`
...
101 | pub fn set_bar(&self) -> &SetBar {
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ duplicate definitions for `set_bar`
This is happening even if I set the generate_getter and generator_accessor to false. Is there any good workaround for this? Maybe it be possible to add an option for adding a prefix to getters, e.g., get_, to disambiguate such cases?
Thanks!
The text was updated successfully, but these errors were encountered:
i believe it is an error for you to use repeated field names in the oneof definition. when i try to reproduce this, i receive a build error:
codegen failed: parse and typecheck
Caused by:
0: using pure parser
1: error in `protos/oneof.proto`: Non-unique field name: `bar`
2: Non-unique field name: `bar`
Furthermore, when i use buf lint on this proto file, it says:
protos/oneof.proto:6:12:symbol "Foo.bar" already defined at oneof.proto:5:9
I have a Protobuf that looks something like this:
When I try to compile the Proto, I get an error along the lines of:
This is happening even if I set the
generate_getter
andgenerator_accessor
to false. Is there any good workaround for this? Maybe it be possible to add an option for adding a prefix to getters, e.g.,get_
, to disambiguate such cases?Thanks!
The text was updated successfully, but these errors were encountered: