Archived
1
Fork 0
This repository has been archived on 2024-10-07. You can view files and clone it, but cannot push or open issues or pull requests.
kilo/include/append_buf.h

15 lines
316 B
C

#ifndef APPEND_BUF_H
#define APPEND_BUF_H
// A simple append only buffer to build strings
struct append_buf {
char *chars;
int n_chars;
};
struct append_buf *ab_init(void);
void ab_append(struct append_buf *ab, const char *chars, int n_chars);
void ab_free(struct append_buf *ab);
#endif // APPEND_BUF_H