revert secondary scaling default in HeaderInfo; rename scaling_difficulty; refactor difficulty_data_to_vector

This commit is contained in:
John Tromp
2018-10-19 21:39:54 +02:00
parent b1ebfe1c73
commit e1b5d7f3c2
15 changed files with 56 additions and 65 deletions
+3 -3
View File
@@ -509,8 +509,8 @@ pub struct BlockHeaderPrintable {
pub cuckoo_solution: Vec<u64>,
/// Total accumulated difficulty since genesis block
pub total_difficulty: u64,
/// Difficulty scaling factor between the different proofs of work
pub scaling_difficulty: u32,
/// Variable difficulty scaling factor for secondary proof of work
pub secondary_scaling: u32,
/// Total kernel offset since genesis block
pub total_kernel_offset: String,
}
@@ -531,7 +531,7 @@ impl BlockHeaderPrintable {
edge_bits: h.pow.edge_bits(),
cuckoo_solution: h.pow.proof.nonces.clone(),
total_difficulty: h.pow.total_difficulty.to_num(),
scaling_difficulty: h.pow.scaling_difficulty,
secondary_scaling: h.pow.secondary_scaling,
total_kernel_offset: h.total_kernel_offset.to_hex(),
}
}