fixed formatting

This commit is contained in:
Vladimir Komendantskiy 2018-12-26 13:10:33 +00:00
parent 767be50088
commit 6db60a1535
4 changed files with 11 additions and 6 deletions

View File

@ -439,7 +439,9 @@ fn main() {
.build_with_transactions(txs.clone(), rng) .build_with_transactions(txs.clone(), rng)
.expect("instantiate QueueingHoneyBadger"); .expect("instantiate QueueingHoneyBadger");
let (sq, mut step) = SenderQueue::builder(qhb, peer_ids.into_iter()).build(our_id); let (sq, mut step) = SenderQueue::builder(qhb, peer_ids.into_iter()).build(our_id);
assert!(step.extend_with(qhb_step, |fault| fault, Message::from).is_empty()); assert!(step
.extend_with(qhb_step, |fault| fault, Message::from)
.is_empty());
(sq, step) (sq, step)
}; };

View File

@ -11,8 +11,8 @@ use serde::{de::DeserializeOwned, Serialize};
use super::votes::{SignedVote, VoteCounter}; use super::votes::{SignedVote, VoteCounter};
use super::{ use super::{
Batch, Change, ChangeState, DynamicHoneyBadgerBuilder, EncryptionSchedule, Error, Input, Batch, Change, ChangeState, DynamicHoneyBadgerBuilder, EncryptionSchedule, Error, FaultKind,
InternalContrib, JoinPlan, KeyGenMessage, KeyGenState, Message, Params, FaultKind, Result, Input, InternalContrib, JoinPlan, KeyGenMessage, KeyGenState, Message, Params, Result,
SignedKeyGenMsg, Step, SignedKeyGenMsg, Step,
}; };
use crate::fault_log::{Fault, FaultLog}; use crate::fault_log::{Fault, FaultLog};

View File

@ -373,7 +373,8 @@ where
MessageContent::DecryptionShare { MessageContent::DecryptionShare {
proposer_id: proposer_id.clone(), proposer_id: proposer_id.clone(),
share, share,
}.with_epoch(self.epoch) }
.with_epoch(self.epoch)
}, },
); );
if let Some(output) = opt_output.into_iter().next() { if let Some(output) = opt_output.into_iter().next() {

View File

@ -145,7 +145,8 @@ impl<N: NodeIdT + Rand, S: SessionIdT> ProposalState<N, S> {
bc_step, bc_step,
|fail| Fault::new(fail.node_id, FaultKind::BroadcastFault(fail.kind)), |fail| Fault::new(fail.node_id, FaultKind::BroadcastFault(fail.kind)),
MessageContent::Broadcast, MessageContent::Broadcast,
).pop(); )
.pop();
Ok((opt_value, step)) Ok((opt_value, step))
} }
@ -158,7 +159,8 @@ impl<N: NodeIdT + Rand, S: SessionIdT> ProposalState<N, S> {
ba_step, ba_step,
|fault| Fault::new(fault.node_id, FaultKind::BaFault(fault.kind)), |fault| Fault::new(fault.node_id, FaultKind::BaFault(fault.kind)),
MessageContent::Agreement, MessageContent::Agreement,
).pop(); )
.pop();
Ok((opt_decision, step)) Ok((opt_decision, step))
} }