andrewhickman / prost-reflect

A protobuf library extending prost with reflection support and dynamic messages.
https://crates.io/crates/prost-reflect
Apache License 2.0
91 stars 21 forks source link

Extend unknown fields API #56

Open andrewhickman opened 1 year ago

andrewhickman commented 1 year ago

52 exposed a way to list unknown fields for a message. We should support more functionality like

There is also currently no API to inspect the value of an unknown field. We could expose something like the UnknownFieldValue enum:

https://github.com/andrewhickman/prost-reflect/blob/15368a7c20b651ecd134d7810c21914202f47371/prost-reflect/src/dynamic/unknown.rs#L24-L37

However if prost ever supports unknown fields, it would be nice to simply re-use its types, so it may be worth staying conservative for now.