X-Git-Url: https://git.nihav.org/?a=blobdiff_plain;f=nihav-core%2Fsrc%2Fio%2Fbitreader.rs;h=26b95a66c98704b203f18d33286b0189398051ee;hb=91f5ad848e8c89177c41e9ac8dc3d3125a1acdd7;hp=11633266068024d02fc339bba23be465033944a4;hpb=26aa3dd30a4b14d566a40d85139076d6fa4e9bb7;p=nihav.git diff --git a/nihav-core/src/io/bitreader.rs b/nihav-core/src/io/bitreader.rs index 1163326..26b95a6 100644 --- a/nihav-core/src/io/bitreader.rs +++ b/nihav-core/src/io/bitreader.rs @@ -35,7 +35,7 @@ /// Bitstream reading modes. -#[derive(Debug)] +#[derive(Debug,Clone,Copy)] pub enum BitReaderMode { /// The stream is big endian MSB first. BE, @@ -48,7 +48,7 @@ pub enum BitReaderMode { } /// A list specifying general bitstream reading errors. -#[derive(Debug)] +#[derive(Debug,Clone,Copy)] pub enum BitReaderError { /// The reader is at the end of bitstream. BitstreamEnd, @@ -64,7 +64,7 @@ use self::BitReaderError::*; pub type BitReaderResult = Result; /// Bitstream reader. -#[derive(Debug)] +#[derive(Debug,Clone)] pub struct BitReader<'a> { cache: u64, bits: u8,