Skip to content

Commit

Permalink
lib.parse: add return document for take_hint_bytes
Browse files Browse the repository at this point in the history
  • Loading branch information
Evian-Zhang authored and m4b committed Aug 18, 2020
1 parent 92a4c29 commit e94ca6b
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/lib.rs
Expand Up @@ -280,6 +280,7 @@ if_everything! {
}

/// Takes a reference to the first 16 bytes of the total bytes slice and convert it to an array for `peek_bytes` to use.
/// Returns None if bytes's length is less than 16.
fn take_hint_bytes(bytes: &[u8]) -> Option<&[u8; 16]> {
use core::convert::TryInto;
bytes.get(0..16)
Expand Down

0 comments on commit e94ca6b

Please sign in to comment.