// // Created by red on 05/12/19. // #include "mpc.h" #ifndef CRISP_EVAL_H #define CRISP_EVAL_H typedef struct { int type; long num; int err; } cval; enum { CVAL_NUM, CVAL_ERR }; enum { CERR_DIV_ZERO, CERR_BAD_OP, CERR_BAD_NUM }; cval eval(mpc_ast_t* t); void cval_print(cval v); void cval_println(cval v); #endif //CRISP_EVAL_H