struct ir_function_s;
typedef struct ir_value_s {
- const char *name;
+ char *name;
ir_type_t vtype;
ir_store_t store;
filecontext_t context;
int vint;
qc_vec_t vvec;
struct ir_value_s *vpointer;
- const char *vstring;
+ char *vstring;
} cvalue;
qbool has_constval;
/* block */
typedef struct ir_block_s
{
- const char *label;
- filecontext_t context;
- qbool final; /* once a jump is added we're done */
+ char *label;
+ lex_ctx_t context;
+ qbool final; /* once a jump is added we're done */
MEM_VECTOR_MAKE(ir_instr*, instr);
MEM_VECTOR_MAKE(struct ir_block_s*, entries);
typedef struct ir_function_s
{
- const char *name;
- ir_type_t retype;
+ char *name;
+ int retype;
MEM_VECTOR_MAKE(ir_type_t, params);
MEM_VECTOR_MAKE(ir_block*, blocks);
ir_block* first;
ir_block* last;
- filecontext_t context;
+ lex_ctx_t context;
/* for temp allocation */
size_t run_id;
/* builder */
typedef struct ir_builder_s
{
- const char *name;
+ char *name;
MEM_VECTOR_MAKE(ir_function*, functions);
MEM_VECTOR_MAKE(ir_value*, globals);
} ir_builder;