Lines Matching defs:stack
2 tre-stack.c - Simple stack implementation
16 #include "tre-stack.h"
29 union tre_stack_item *stack;
41 s->stack = xmalloc(sizeof(*s->stack) * size);
42 if (s->stack == NULL)
58 xfree(s->stack);
73 s->stack[s->ptr] = value;
80 DPRINT(("tre_stack_push: stack full\n"));
91 new_buffer = xrealloc(s->stack, sizeof(*new_buffer) * new_size);
100 s->stack = new_buffer;
119 return s->stack[--s->ptr].typetag ## _value; \