Function toArrayList [src]
Prototype
pub fn toArrayList(w: *Writer) ArrayList(u8)
Parameters
w: *Writer
Source
pub fn toArrayList(w: *Writer) ArrayList(u8) {
const result: ArrayList(u8) = .{
.items = w.buffer[0..w.end],
.capacity = w.buffer.len,
};
w.buffer = &.{};
w.end = 0;
return result;
}