From b0cfde89c4ed03aa7af4e38b6ce8a36fca8da7b6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ahmet=20Kaan=20G=C3=BCm=C3=BC=C5=9F?= Date: Wed, 2 Dec 2026 13:33:31 +0300 Subject: [PATCH] U5: remove unused ec-vp8 BoolDecoder::byte_offset and read_tree_no_root_eob No caller in edith, yumush or ec-vp8; rustc flags neither as used once the trace gate is gone. --- crates/ec-vp8/src/bool.rs | 21 --------------------- 1 file changed, 21 deletions(-) diff --git a/crates/ec-vp8/src/bool.rs b/crates/ec-vp8/src/bool.rs index 58293009..82bccdc2 100644 --- a/crates/ec-vp8/src/bool.rs +++ b/crates/ec-vp8/src/bool.rs @@ -67,11 +67,6 @@ impl<'a> BoolDecoder<'a> { self.overreads } - /// Offset of the next unread input byte, for desync diagnostics. - pub fn byte_offset(&self) -> usize { - self.pos - } - fn next_byte(&mut self) -> u32 { match self.data.get(self.pos) { Some(&b) => { @@ -170,22 +165,6 @@ impl<'a> BoolDecoder<'a> { } } - /// Decode a tree-coded value, skipping the root's `dct_eob` branch — - /// used for every token after a `DCT_0`, since EOB cannot follow a - /// zero token (RFC §13.2). `tree` must be the full coefficient tree; - /// decoding starts at interior node 1. - pub fn read_tree_no_root_eob(&mut self, tree: &[i8], probs: &[u8]) -> u8 { - // The coefficient tree's layout puts the EOB leaf at the root's - // left branch; descending the right branch first is exactly - // "start at the root with a read 1". - let mut i: i32 = i32::from(tree[1]); // interior node reached on the "1" branch - while { - let b = self.read_bool(probs[(i >> 1) as usize]); - i = i32::from(tree[(i + i32::from(b as i8)) as usize]); - i > 0 - } {} - (-i) as u8 - } } /// The RFC 6386 §7.3 reference `bool_encoder`, test-only: it lets the tests