diff options
author | Clyne Sullivan <tullivan99@gmail.com> | 2018-01-29 20:19:22 -0500 |
---|---|---|
committer | Clyne Sullivan <tullivan99@gmail.com> | 2018-01-29 20:19:22 -0500 |
commit | b9ceb80c9caa2a4a1659615991e7daa0b1d9fb66 (patch) | |
tree | bc0720404a935018c75524555d90a320512398c6 /old/variable.h | |
parent | accef5f54c0a38b0de3c2dddbaf7b30c6d226541 (diff) |
rewrite; a lot better now
Diffstat (limited to 'old/variable.h')
-rw-r--r-- | old/variable.h | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/old/variable.h b/old/variable.h new file mode 100644 index 0000000..fd84a6e --- /dev/null +++ b/old/variable.h @@ -0,0 +1,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_ |