Modification of extension fields #623
Unanswered
woshilapin
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi, I'm currently migrating from
protobuf:2.27.1
toprotobuf:3.0.2
.I'm trying to change the value of a field that is part of an Protobuf extension.
I'm able to access the unknown fields mutably with something like
MyMessage.special_fields.mut_unknown_fields()
but then I'm trying to useadd_varint
and I don't know how to provide thenumber
.In
protobuf:2.27.1
, I used to be able to do something likemy_proto::exts::my_field.field_number
but it seems thatfield_number
is now a private field. Is there a new way to do that?I'm pretty new to Protobuf in general and especially
protobuf
's crate, so it's possible I missed something.Beta Was this translation helpful? Give feedback.
All reactions