diff options
Diffstat (limited to 'rushs/evalexpr/src/stack.h')
| -rw-r--r-- | rushs/evalexpr/src/stack.h | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/rushs/evalexpr/src/stack.h b/rushs/evalexpr/src/stack.h new file mode 100644 index 0000000..d08e465 --- /dev/null +++ b/rushs/evalexpr/src/stack.h @@ -0,0 +1,20 @@ +#ifndef STACK_H +#define STACK_H + +#include "evalexpr.h" +#include "stack_struct.h" + +struct tstack +{ + struct token *token; + struct tstack *next; +}; + +struct stack *stack_push(struct stack *s, int e); +struct stack *stack_pop(struct stack *s); +int stack_peek(struct stack *s); + +struct tstack *tstack_push(struct tstack *s, struct token *e); +struct tstack *tstack_pop(struct tstack *s); +struct token *tstack_peek(struct tstack *s); +#endif /* !STACK_H */ |
