17 lines
392 B
C
17 lines
392 B
C
|
#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;
|
||
|
}
|