#ifndef _BUF_INCLUDE #define _BUF_INCLUDE typedef struct buf_node buf_node; typedef struct buf buf; buf* newbuf(size_t cap); void addchrbuf(buf* buffer, char chr); // front void addstrbuf(buf* buffer, char* str); char remchrbuf(buf* buffer); char* remstrbuf(buf* buffer, int ct); void prechrbuf(buf* buffer, char chr); // back void prestrbuf(buf* buffer, char* str); char shfchrbuf(buf* buffer); char* shfstrbuf(buf* buffer, int ct); char* strpeekbuf(buf* buffer, int loc); #endif