pilota 0.12.0

Pilota is a thrift and protobuf implementation in pure rust with high performance and extensibility.
Documentation
fn main() {}

pub mod string {
    #![allow(warnings, clippy::all)]
    #[derive(PartialOrd, Hash, Eq, Ord, Debug, Default, Clone, PartialEq)]
    pub struct A {
        pub a: ::std::option::Option<::pilota::FastStr>,
        pub b: ::pilota::FastStr,
    }
    impl ::pilota::prost::Message for A {
        #[inline]
        fn encoded_len(&self) -> usize {
            0 + self.a.as_ref().map_or(0, |value| {
                ::pilota::prost::encoding::string::encoded_len(1u32, value)
            }) + ::pilota::prost::encoding::string::encoded_len(2u32, &self.b)
        }
        #[allow(unused_variables)]
        fn encode_raw<B>(&self, buf: &mut B)
        where
            B: ::pilota::prost::bytes::BufMut,
        {
            if let Some(_pilota_inner_value) = self.a.as_ref() {
                ::pilota::prost::encoding::string::encode(1u32, _pilota_inner_value, buf);
            }
            ::pilota::prost::encoding::string::encode(2u32, &self.b, buf);
        }
        #[allow(unused_variables)]
        fn merge_field<B>(
            &mut self,
            tag: u32,
            wire_type: ::pilota::prost::encoding::WireType,
            buf: &mut B,
            ctx: ::pilota::prost::encoding::DecodeContext,
        ) -> ::core::result::Result<(), ::pilota::prost::DecodeError>
        where
            B: ::pilota::prost::bytes::Buf,
        {
            const STRUCT_NAME: &'static str = stringify!(A);
            match tag {
                1u32 => {
                    let mut _inner_pilota_value = &mut self.a;
                    ::pilota::prost::encoding::string::merge(
                        wire_type,
                        _inner_pilota_value.get_or_insert_with(::core::default::Default::default),
                        buf,
                        ctx,
                    )
                    .map_err(|mut error| {
                        error.push(STRUCT_NAME, stringify!(a));
                        error
                    })
                }
                2u32 => {
                    let mut _inner_pilota_value = &mut self.b;
                    ::pilota::prost::encoding::string::merge(
                        wire_type,
                        _inner_pilota_value,
                        buf,
                        ctx,
                    )
                    .map_err(|mut error| {
                        error.push(STRUCT_NAME, stringify!(b));
                        error
                    })
                }
                _ => ::pilota::prost::encoding::skip_field(wire_type, tag, buf, ctx),
            }
        }
    }
}