diff options
Diffstat (limited to 'libc/inc/stack.h')
-rw-r--r-- | libc/inc/stack.h | 28 |
1 files changed, 0 insertions, 28 deletions
diff --git a/libc/inc/stack.h b/libc/inc/stack.h deleted file mode 100644 index f5ad52b..0000000 --- a/libc/inc/stack.h +++ /dev/null @@ -1,28 +0,0 @@ -// MIT License, Copyright (c) 2020 Marvin Borner - -#ifndef STACK_H -#define STACK_H - -#include <def.h> - -struct stack_node { - void *data; - int nonce; - struct stack_node *next; - struct stack_node *prev; -}; - -struct stack { - struct stack_node *tail; -}; - -struct stack *stack_new(void); -void stack_destroy(struct stack *stack); -u32 stack_empty(struct stack *stack); -u32 stack_push_bot(struct stack *stack, void *data); -u32 stack_push(struct stack *stack, void *data); -void *stack_pop(struct stack *stack); -void *stack_peek(struct stack *stack); -void stack_clear(struct stack *stack); - -#endif |