core: tokbuf: Fix up token buffer

Signed-off-by: Chloe M. <chloe@mirocom.org>
This commit is contained in:
2026-05-23 19:01:51 -04:00
parent dba31ae0ad
commit 71f232282a
2 changed files with 37 additions and 10 deletions
+10
View File
@@ -37,6 +37,16 @@ int tokbuf_init(struct tokbuf *tokbuf);
*/
int tokbuf_push(struct tokbuf *tokbuf, struct token *tok);
/*
* Pop a token from the token buffer
*
* @tokbuf: Token buffer to pop from
* @res: Result is written here
*
* Returns zero on success
*/
int tokbuf_pop(struct tokbuf *tokbuf, struct token *res);
/*
* Peek at the token buffer from a negative offset backwards
*