1
0
Fork 0
lesson-lisp/enums.c

17 lines
392 B
C
Raw Normal View History

2023-05-03 17:28:58 -04:00
#include "enums.h"
#include <stddef.h>
const char *State_to_str(enum State state)
{
switch (state) {
case STATE_INIT: return "STATE_INIT";
case STATE_WHITESPACE: return "STATE_WHITESPACE";
case STATE_OPEN: return "STATE_OPEN";
case STATE_CLOSE: return "STATE_CLOSE";
case STATE_ID: return "STATE_ID";
case STATE_NUM: return "STATE_NUM";
}
return NULL;
}