make while loop parsing more elegant
It is now possible to parse parts of the program and save the IR for later addition. This is currently used for while loops but will also make other control flow elements easier to implement in the future.
This commit is contained in:
4
ir.h
4
ir.h
@@ -74,9 +74,11 @@ typedef struct IRToks {
|
||||
IRTok *toks;
|
||||
} IRToks;
|
||||
|
||||
void irtoks_init(IRToks *v);
|
||||
void irtoks_init_long(IRToks *v);
|
||||
void irtoks_init_short(IRToks *v);
|
||||
void irtoks_term(IRToks *v);
|
||||
void irtoks_app(IRToks *v, IRTok t);
|
||||
void irtoks_app_irtoks(IRToks *v, IRToks *other);
|
||||
|
||||
void print_ir(IRToks *v);
|
||||
|
||||
|
Reference in New Issue
Block a user