Function zksync_protobuf::canonical_raw

source ·
pub fn canonical_raw(buf: &[u8], desc: &MessageDescriptor) -> Result<Vec<u8>>
Expand description

Converts an encoded protobuf message to its canonical form, given the descriptor of the message type. Returns an error if:

  • an unknown field is detected
  • the message type doesn’t support canonical encoding (implicit presence, map fields)