void rdesc_stack_reset(struct rdesc_stack **stack)
Clears the stack and resets capacity to initial size.
size_t rdesc_stack_len(const struct rdesc_stack *stack)
Returns the current number of elements in the stack.
void * rdesc_stack_at(struct rdesc_stack *stack, size_t index)
Returns pointer to the element at the specified index.
void * rdesc_stack_multipop(struct rdesc_stack **stack, size_t count)
Pops multiple elements from the stack, and returns pointer to the element that was at the bottom of t...
void * rdesc_stack_push(struct rdesc_stack **stack, void *element)
Pushes a single element onto the stack.
void * rdesc_stack_multipush(struct rdesc_stack **stack, void *elements, size_t count)
Pushes multiple elements onto the stack.
void * rdesc_stack_pop(struct rdesc_stack **stack)
Removes and returns the top element from the stack.
void rdesc_stack_init(struct rdesc_stack **stack, size_t element_size)
Initializes a new stack with the specified element size.
void * rdesc_stack_top(struct rdesc_stack *stack)
Returns the top element without removing it.
void rdesc_stack_destroy(struct rdesc_stack *stack)
Frees all memory allocated by the stack.
Default implementation of the stack.