mirror of
https://github.com/mii443/merkle.rs.git
synced 2025-08-22 16:05:30 +00:00
fix formatting according to rustfmt
This commit is contained in:
committed by
Romain Ruetschi
parent
7a1add13a1
commit
7befdf94a2
@ -1,6 +1,8 @@
|
||||
#![deny(missing_docs, unused_qualifications, missing_debug_implementations,
|
||||
missing_copy_implementations, trivial_casts, trivial_numeric_casts, unsafe_code,
|
||||
unstable_features, unused_import_braces)]
|
||||
#![deny(
|
||||
missing_docs, unused_qualifications, missing_debug_implementations,
|
||||
missing_copy_implementations, trivial_casts, trivial_numeric_casts, unsafe_code,
|
||||
unstable_features, unused_import_braces
|
||||
)]
|
||||
|
||||
//! *merkle* implements a Merkle Tree in Rust.
|
||||
|
||||
|
@ -28,7 +28,9 @@ pub struct MerkleTree<T> {
|
||||
impl<T: PartialEq> PartialEq for MerkleTree<T> {
|
||||
#[allow(trivial_casts)]
|
||||
fn eq(&self, other: &MerkleTree<T>) -> bool {
|
||||
self.root == other.root && self.height == other.height && self.count == other.count
|
||||
self.root == other.root
|
||||
&& self.height == other.height
|
||||
&& self.count == other.count
|
||||
&& (self.algorithm as *const Algorithm) == (other.algorithm as *const Algorithm)
|
||||
}
|
||||
}
|
||||
|
@ -52,8 +52,10 @@ mod algorithm_serde {
|
||||
|
||||
mod test {
|
||||
use super::*;
|
||||
use ring::digest::{SHA1 as sha1, SHA256 as sha256, SHA384 as sha384, SHA512 as sha512,
|
||||
SHA512_256 as sha512_256};
|
||||
use ring::digest::{
|
||||
SHA1 as sha1, SHA256 as sha256, SHA384 as sha384, SHA512 as sha512,
|
||||
SHA512_256 as sha512_256,
|
||||
};
|
||||
|
||||
static SHA1: &Algorithm = &sha1;
|
||||
static SHA256: &Algorithm = &sha256;
|
||||
|
Reference in New Issue
Block a user