quick-protobuf
quick-protobuf copied to clipboard
convert enum to string?
is there a way to nicely convert an enum to its string representation? I see that there is a (very useful) from(&str) method, but what about the inverse, something like to_string()?
the current way i am doing it requires a somewhat ugly format!("{:?}", foo) since the enums have the Debug trait
i migrated from rust-protobuf to this library, and they had a to_string() func