File tree 2 files changed +7
-4
lines changed
2 files changed +7
-4
lines changed Original file line number Diff line number Diff line change 11
11
//! Little-Endian order has been chosen for internal usage; this makes some
12
12
//! useful functions available.
13
13
14
- /// Reads unsigned 32 bit integers from `src` into `dst`.
14
+ /// Fills `dst: &mut [u32]` from `src`
15
+ ///
16
+ /// Reads use Little-Endian byte order, allowing portable reproduction of `dst`
17
+ /// from a byte slice.
15
18
///
16
19
/// # Panics
17
20
///
18
- /// If `dst ` has insufficient space (`4*dst .len() < src .len()`).
21
+ /// If `src ` has insufficient length (if `src .len() < 4*dst .len()`).
19
22
#[ inline]
20
23
#[ track_caller]
21
24
pub fn read_u32_into ( src : & [ u8 ] , dst : & mut [ u32 ] ) {
@@ -25,11 +28,11 @@ pub fn read_u32_into(src: &[u8], dst: &mut [u32]) {
25
28
}
26
29
}
27
30
28
- /// Reads unsigned 64 bit integers from `src` into `dst`.
31
+ /// Fills `dst: &mut [u64]` from `src`
29
32
///
30
33
/// # Panics
31
34
///
32
- /// If `dst ` has insufficient space (`8*dst .len() < src .len()`).
35
+ /// If `src ` has insufficient length (if `src .len() < 8*dst .len()`).
33
36
#[ inline]
34
37
#[ track_caller]
35
38
pub fn read_u64_into ( src : & [ u8 ] , dst : & mut [ u64 ] ) {
You can’t perform that action at this time.
0 commit comments