SICP/shared/scm2c/stack.h

19 lines
276 B
C

#ifndef STACK_H
#define STACK_H
typedef struct stack_elem {
void *value;
struct stack_elem *next;
} stack_elem;
typedef struct stack {
struct stack_elem *first;
} stack;
stack* create_stack(void);
void save(void *d, stack *s);
void* restore(stack *s);
#endif