Implement buffer traits on Vec<u8>, &[u8], Cursor

This commit is contained in:
Carl Lerche
2015-07-24 16:52:19 -07:00
parent 23ad12f842
commit 296cac263c
4 changed files with 131 additions and 1 deletions
+3
View File
@@ -9,6 +9,9 @@ use std::{cmp, ptr};
*/
/// A `Buf` backed by a contiguous region of memory.
///
/// This `Buf` is better suited for cases where there is a clear delineation
/// between reading and writing.
pub struct ByteBuf {
mem: alloc::MemRef,
cap: u32,