From 6a9466da5377d0bc73c7e5aa48deca3740d3de6f Mon Sep 17 00:00:00 2001 From: dec05eba Date: Sun, 31 Mar 2019 13:44:27 +0200 Subject: Test errors, stop working on error --- include/std/buffer.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include/std') diff --git a/include/std/buffer.h b/include/std/buffer.h index a1bfb01..723ef6c 100644 --- a/include/std/buffer.h +++ b/include/std/buffer.h @@ -20,6 +20,8 @@ CHECK_RESULT int buffer_init(Buffer *self, struct ScopedAllocator *allocator); CHECK_RESULT int buffer_append(Buffer *self, const void *data, usize size); void* buffer_get(Buffer *self, usize index, usize type_size); CHECK_RESULT int buffer_pop(Buffer *self, void *data, usize size); +/* Set buffer size to 0, doesn't reallocate */ +void buffer_clear(Buffer *self); void* buffer_start(Buffer *self); void* buffer_end(Buffer *self); usize __buffer_get_size(Buffer *self, usize type_size); -- cgit v1.2.3