1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22
#ifndef PARSER_H #define PARSER_H extern int blen; enum btype { BEGIN = 1, END, OBJ, COLON, IDENTIFIER, VALUE }; struct byte { enum btype type; char *value; }; struct byte *parse(unsigned char *buf); #endif