#ifndef RZ_VALUE_H #define RZ_VALUE_H #include "type.h" #include "fun.h" struct program; typedef struct { type_t* type; union { double num; int bool; char* str; fun_t* fun; } value; int line; } value_t; void value_init(value_t* value, type_t* type, int line); void value_free(value_t* value); int value_eq(value_t* value, value_t* rhs); size_t value_str(value_t* value, char* buffer, size_t size); #endif