fn shift_right_serializer<S>(original_array: &Vec<i16>, serializer: S) -> Result<S::Ok, S::Error>
where
    S: Serializer,
{
    nbt::i8_array(original_array.iter().map(|&i| (i >> 8) as i8), serializer)
}
// We want to serialize an i16 vector as a ByteArray by shifting every element right by 8 bits
We want to serialize an i16 vector as a ByteArray by shifting every element right by 8 bits
We want to serialize an i16 vector as a ByteArray by shifting every element right by 8 bits
fn shift_right_serializer<S>(original_array: &Vec<i16>, serializer: S) -> Result<S::Ok, S::Error>
where
    S: Serializer,
{
    nbt::i8_array(original_array.iter().map(|&i| (i >> 8) as i8), serializer)
}
fn shift_right_serializer < S > ( original_array : & Vec < i16 > , serializer : S ) -> Result < S :: Ok , S :: Error > where S : Serializer , { nbt :: i8_array ( original_array . iter ( ) . map ( | & i | ( i >> 8 ) as i8 ) , serializer ) }
We want to serialize an i16 vector as a ByteArray by shifting every element right by 8 bits
We want to serialize an i16 vector as a ByteArray by shifting every element right by 8 bits
original_array
&Vec<i16>
serializer
S