Skip to content

Commit 228a85f

Browse files
committed
bit_machine: put pub(super) on all public methods of Frame
This whole type is pub(super). It should not have public methods.
1 parent 8622a8f commit 228a85f

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

src/bit_machine/frame.rs

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,12 +34,12 @@ impl Frame {
3434
}
3535

3636
/// Return the start index of the frame inside the referenced data.
37-
pub fn start(&self) -> usize {
37+
pub(super) fn start(&self) -> usize {
3838
self.start
3939
}
4040

4141
/// Return the bit width of the frame.
42-
pub fn bit_width(&self) -> usize {
42+
pub(super) fn bit_width(&self) -> usize {
4343
self.len
4444
}
4545

@@ -104,7 +104,10 @@ impl Frame {
104104

105105
/// Extend the present frame with a read-only reference the the data
106106
/// and return the resulting struct.
107-
pub(super) fn as_bit_iter<'a>(&self, data: &'a [u8]) -> super::FrameIter<'a> {
107+
pub(super) fn as_bit_iter<'a>(
108+
&self,
109+
data: &'a [u8],
110+
) -> BitIter<core::iter::Copied<core::slice::Iter<'a, u8>>> {
108111
BitIter::byte_slice_window(data, self.start, self.start + self.len)
109112
}
110113
}

0 commit comments

Comments
 (0)