1) output \n in string literals - C cannot handle literal newlines 2) need to undef array macros at end of scope 3) terminating condition on for loops!: DONE. (although can do better if constant bounds and we can see the values of the constants) < for (K = -7; K <= 0; K++) <- <= executes with K = 0 < Tline[K] = ' '; --- > for (K = -7; K != 0; K += 1) { <- != does not execute with K = 0 Maybe use K != 0+1 > TLINE[(K) - (-60)] = ' '; > } 4) assignment to array elements A[R] = 2 * (I + J); 5) Replace ('0' <= I && I <= '9') with isdigit(I) 6) Accidentally doubled quotes 1777,1784c2753,2761 < Quote:; < if (Cc[Q + 2] == '\'') { --- > QUOTE: > if (CC[(Q + 2) - (0)] == '\'\'') { 7) LOW...HIGH 8) Problem with comment for %UNTIL ... %CYCLE 9) asm() 10) constant expressions, then conditional compilation 11) unless/until 12) conditions as AST tree, allow DeMorgan 13) replace const int with #define's 14) Missing MOD() call? - no, I just forgot to include the perms on that run! 15) RECORD() and ARRAY() 16) All expressions to be available as an AST tree so that the tree can be modified. This will allow: a) removal of $define ra[N0] b) tidier indexing and constant folding 17) %switch declarations not yet output 18) == assignments - &RHS 19) Writing through %names and %maps - *name 20) (ignore the lack of record fields): %IF C1_CMP2=0 %AND 7<=FCOMP(C1_CMP1)<=8 %AND A(P2+3)=4 %AND %C A(P2+4)=2 %AND A(P2+5)=X'35' %AND A(P2+10)=0 %C %AND A(P2+11)=2 %THEN %START translated to if (C1 == 0 && 7 <= FCOMP[(C1) - (1)] && FCOMP[(C1) - (1)] = 8 && A == 4 && A == 2 && A == 0x35 && A == 0 && A == 2) { - note the <= 8 became < 8 !!??!?!? -------------------- 21) Current data structure for arrays is: --- A Var is represented by a VarDecl (indexed by a VarDeclIDX) A VarDecl contains a TypeDecl (indexed by a TypeDeclIDX) A TypeDecl contains an arrfm (indexed by an ArrayFormatIDX) An arrfm contains the dims and an array of BoundsPairs A BoundsPair contains two Bounds A bound contains a value as an ASTidx into AST[] (and a 'type' enum for later expansion. Probably can remove for now.) ---- That's too messy. Here's the simplified version: