When running good13.cc, we currently get the error message:
Inconsistent stack height 1 != 0
From testing, it seems like the problem lies in how we handle our while-loops. So, our questions are twofold:
1) What does the error message actually mean? It's obvious that it refers to the size of the stack, but does it mean that the stack is too large or too small?
2) Is the way that we handle loops correct?
SWhile exp stm -> do loop <- newLabel
false <- newLabel
emit $ loop ++ ":"
compileExp exp
emit $ "ifeq " ++ false
compileStm stm
emit $ "goto " ++ loop
emit $ false ++ ":"