Fixed some warnings
This commit is contained in:
@@ -51,7 +51,7 @@ impl Simulator {
|
||||
.iter()
|
||||
.map(|node| {
|
||||
let node_clone = Arc::clone(node);
|
||||
let start_clone = start.clone();
|
||||
let start_clone = start;
|
||||
thread::spawn(move || {
|
||||
while start_clone.elapsed() < duration {
|
||||
node_clone.submit_price();
|
||||
@@ -64,7 +64,7 @@ impl Simulator {
|
||||
// Spawn network propagation thread
|
||||
let nodes_clone = self.nodes.clone();
|
||||
let partitioned_clone = Arc::clone(&self.partitioned);
|
||||
let start_clone = start.clone();
|
||||
let start_clone = start;
|
||||
let propagation_handle = thread::spawn(move || {
|
||||
while start_clone.elapsed() < duration {
|
||||
let is_partitioned = *partitioned_clone.lock().unwrap();
|
||||
@@ -80,7 +80,7 @@ impl Simulator {
|
||||
|
||||
let crdt1 = nodes_clone[i].crdt.lock().unwrap();
|
||||
let mut crdt2 = nodes_clone[j].crdt.lock().unwrap();
|
||||
crdt2.merge(&*crdt1);
|
||||
crdt2.merge(&crdt1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user