Merge branch 'FunctionCalls' into DontBreakDev

This commit is contained in:
Annie Slenker
2025-05-02 16:26:33 -04:00
committed by GitHub
9 changed files with 122 additions and 16 deletions

View File

@ -38,6 +38,9 @@ typedef union TNConstUnion TNConstUnion;
typedef struct Instruction Instruction;
typedef struct TNodeOrConst TNodeOrConst;
// these are from page 364
typedef enum { // these are from page 364
E_LABEL = 10000, // this is not in the book
E_FUNC_START,
@ -166,3 +169,6 @@ bool isConst(TNodeOrConst * tnc);
int label_gen();
void backpatch(Stack *s, int l);
void emit_backpatch(Stack *s, int l);
extern int offset;
extern int currentsp;
extern CGNode* cgList;