source: doc/papers/general/evaluation/c-stack.h @ e59f0bf

aaron-thesisarm-ehcleanup-dtorsdeferred_resndemanglerjacob/cs343-translationjenkins-sandboxnew-astnew-ast-unique-exprnew-envno_listpersistent-indexerresolv-newwith_gc
Last change on this file since e59f0bf was e59f0bf, checked in by Aaron Moss <a3moss@…>, 4 years ago

Update benchmarks so that C has assign operator like others

  • Property mode set to 100644
File size: 505 bytes
Line 
1#pragma once
2
3struct stack_node;
4struct stack {
5        struct stack_node* head;
6};
7
8struct stack new_stack();
9void copy_stack(struct stack* dst, const struct stack* src, void* (*copy)(const void*));
10struct stack* assign_stack(struct stack* dst, const struct stack* src, 
11        void* (*copy_el)(const void*), void (*free_el)(void*));
12void clear_stack(struct stack* s, void (*free_el)(void*));
13
14_Bool stack_empty(const struct stack* s);
15void push_stack(struct stack* s, void* value);
16void* pop_stack(struct stack* s);
Note: See TracBrowser for help on using the repository browser.