Go to the documentation of this file.
42 unsigned short max_size;
50 const void_stack* stack;
52 } void_stack_iterator;
const void * void_stack_cur(const void_stack *stack)
Returns a pointer to the current element on the top of the stack.
Definition: void_stack.c:138
const void * void_stack_iterator_next(void_stack_iterator *iter)
Returns a pointer to the the next element in the stack.
Definition: void_stack.c:173
void void_stack_iterator_free(void_stack_iterator *iter)
Frees a void_stack_iterator.
Definition: void_stack.c:167
void * void_stack_pop(void_stack *stack)
Removes the top element on a void_stack and returns a reference to it.
Definition: void_stack.c:112
void void_stack_iterator_free(void_stack_iterator *iter)
Frees a void_stack_iterator.
Definition: void_stack.c:167
void void_stack_free(void_stack *stack)
Frees the memory associated with a void_stack, but not the elements held on the stack.
Definition: void_stack.c:91
bool void_stack_push(void_stack *stack, void *e)
Puts a new element on the top of a void_stack.
Definition: void_stack.c:126
void_stack_iterator * void_stack_iterator_new(const void_stack *stack)
Creates a new iterator for the specified void_stack.
Definition: void_stack.c:149
unsigned short void_stack_size(const void_stack *stack)
Query the current number of elements on a void_stack()
Definition: void_stack.c:106
void * void_stack_pop(void_stack *stack)
Removes the top element on a void_stack and returns a reference to it.
Definition: void_stack.c:112
void void_stack_free(void_stack *stack)
Frees the memory associated with a void_stack, but not the elements held on the stack.
Definition: void_stack.c:91
void_stack_iterator * void_stack_iterator_new(const void_stack *stack)
Creates a new iterator for the specified void_stack.
Definition: void_stack.c:149
void_stack * void_stack_new(unsigned short max_size)
Allocates a new void_stack.
Definition: void_stack.c:27
void_stack * void_stack_copy(const void_stack *v)
Makes a shallow copy of void_stack.
Definition: void_stack.c:53
void_stack * void_stack_copy_reverse(const void_stack *v)
Makes a shallow copy of void_stack in reverse order.
Definition: void_stack.c:72
void_stack * void_stack_copy_reverse(const void_stack *v)
Makes a shallow copy of void_stack in reverse order.
Definition: void_stack.c:72
const void * void_stack_iterator_next(void_stack_iterator *iter)
Returns a pointer to the the next element in the stack.
Definition: void_stack.c:173
void void_stack_free_deep(void_stack *stack)
Frees the memory associated with a void_stack and the elements referenced by the stack.
Definition: void_stack.c:97
void_stack * void_stack_new(unsigned short max_size)
Allocates a new void_stack.
Definition: void_stack.c:27
bool void_stack_push(void_stack *stack, void *e)
Puts a new element on the top of a void_stack.
Definition: void_stack.c:126
void_stack * void_stack_copy(const void_stack *v)
Makes a shallow copy of void_stack.
Definition: void_stack.c:53
unsigned short void_stack_size(const void_stack *stack)
Query the current number of elements on a void_stack()
Definition: void_stack.c:106
const void * void_stack_cur(const void_stack *stack)
Returns a pointer to the current element on the top of the stack.
Definition: void_stack.c:138
XXX: document this.
Definition: void_stack.h:39
XXX: document this.
Definition: void_stack.h:48
void void_stack_free_deep(void_stack *stack)
Frees the memory associated with a void_stack and the elements referenced by the stack.
Definition: void_stack.c:97