Skip to content

Commit

Permalink
fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
newpavlov committed Mar 3, 2021
1 parent 21b03cc commit fd8b436
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 7 deletions.
14 changes: 8 additions & 6 deletions aead/src/stream.rs
Original file line number Diff line number Diff line change
Expand Up @@ -226,7 +226,7 @@ macro_rules! impl_stream_object {
pub fn new(key: &Key<A>, nonce: &Nonce<A, S>) -> Self
where
A: NewAead,
S: NewStream<A>
S: NewStream<A>,
{
Self::from_stream_primitive(S::new(key, nonce))
}
Expand All @@ -237,7 +237,7 @@ macro_rules! impl_stream_object {
pub fn from_aead(aead: A, nonce: &Nonce<A, S>) -> Self
where
A: NewAead,
S: NewStream<A>
S: NewStream<A>,
{
Self::from_stream_primitive(S::from_aead(aead, nonce))
}
Expand Down Expand Up @@ -291,7 +291,8 @@ macro_rules! impl_stream_object {
return Err(Error);
}

self.stream.$in_place_op(self.position, false, associated_data, buffer)?;
self.stream
.$in_place_op(self.position, false, associated_data, buffer)?;

// Note: overflow checked above
self.position += S::COUNTER_INCR;
Expand Down Expand Up @@ -322,12 +323,13 @@ macro_rules! impl_stream_object {
pub fn $last_in_place_method(
self,
associated_data: &[u8],
buffer: &mut dyn Buffer
buffer: &mut dyn Buffer,
) -> Result<(), Error> {
self.stream.$in_place_op(self.position, true, associated_data, buffer)
self.stream
.$in_place_op(self.position, true, associated_data, buffer)
}
}
}
};
}

impl_stream_object!(
Expand Down
2 changes: 1 addition & 1 deletion crypto-mac/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ pub mod dev;
#[cfg_attr(docsrs, doc(cfg(feature = "core-api")))]
pub mod core_api;

pub use cipher::{errors::InvalidLength, FromKey};
pub use crypto_common::{FixedOutput, FixedOutputReset, Reset, Update};
pub use cipher::{FromKey, errors::InvalidLength};
pub use generic_array::{self, typenum::consts};

use core::fmt;
Expand Down

0 comments on commit fd8b436

Please sign in to comment.