Fix comments

This commit is contained in:
Tangent 128 2017-01-12 07:55:49 -05:00
parent 502da6b29d
commit a171b18e4f

View file

@ -8,7 +8,9 @@ pub enum Error {
#[derive(Debug, PartialEq)] #[derive(Debug, PartialEq)]
pub enum Varint { pub enum Varint {
/// a numeric value
Value(u64), Value(u64),
/// the reserved "unknown" value
Unknown Unknown
} }
@ -16,7 +18,7 @@ pub enum Varint {
/// Returns an Err() if the format is corrupt. /// Returns an Err() if the format is corrupt.
/// Returns Ok(None) if more bytes are needed to get a result. /// Returns Ok(None) if more bytes are needed to get a result.
/// Returns Ok(Some((varint, next))) to return a varint value and /// Returns Ok(Some((varint, next))) to return a varint value and
/// the starting location fo the next /// the size of the parsed varint.
pub fn decode_varint(bytes: &[u8]) -> Result<Option<(Varint, usize)>, Error> { pub fn decode_varint(bytes: &[u8]) -> Result<Option<(Varint, usize)>, Error> {
let mut value: u64 = 0; let mut value: u64 = 0;
let mut value_length = 1; let mut value_length = 1;