1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
#ifndef TOKEN_H_ #define TOKEN_H_ #include <stdint.h> typedef struct { uint16_t nameidx; uint8_t type; uint8_t info; uint32_t value; } variable; #define INFO_ARGS(x) ((x) & 0x07) #define INFO_RET (1 << 3) enum vartype { VALUE = 0, VARIABLE, OPERATOR, FUNCTION, CFUNCTION }; #endif // TOKEN_H_