Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #![rustfmt::skip::macros(named, do_parse, call, take)]
- fn main() {
- named!(from_bytes<ClientHandshake>, do_parse!(
- pk: call!(PublicKey::from_bytes) >>
- nonce: call!(Nonce::from_bytes) >>
- payload: take!(ENC_PAYLOAD_SIZE) >>
- (ClientHandshake { pk, nonce, payload: payload.to_vec() })
- ));
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement