From 717da4bf69da3c43ef2bbcd842fd65703d488c34 Mon Sep 17 00:00:00 2001 From: "Jamil Lambert, PhD" Date: Tue, 25 Jun 2024 14:23:10 +0100 Subject: [PATCH] Capitalize Huffman Huffman is a proper noun and should be capitalized in docs and strings. Capitalize all occurances of Huffman in docs and strings. --- bitcoin/src/taproot/mod.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bitcoin/src/taproot/mod.rs b/bitcoin/src/taproot/mod.rs index 153c55593..ff66716c4 100644 --- a/bitcoin/src/taproot/mod.rs +++ b/bitcoin/src/taproot/mod.rs @@ -422,14 +422,14 @@ impl TaprootBuilder { // Insert the sum of first two in the tree as a new node // N.B.: p1 + p2 can not practically saturate as you would need to have 2**32 max u32s // from the input to overflow. However, saturating is a reasonable behavior here as - // huffman tree construction would treat all such elements as "very likely". + // Huffman tree construction would treat all such elements as "very likely". let p = Reverse(p1.0.saturating_add(p2.0)); node_weights.push((p, NodeInfo::combine(s1, s2)?)); } // Every iteration of the loop reduces the node_weights.len() by exactly 1 // Therefore, the loop will eventually terminate with exactly 1 element debug_assert_eq!(node_weights.len(), 1); - let node = node_weights.pop().expect("huffman tree algorithm is broken").1; + let node = node_weights.pop().expect("Huffman tree algorithm is broken").1; Ok(TaprootBuilder { branch: vec![Some(node)] }) }