new version number
authorceriel <none@none>
Fri, 4 Nov 1988 10:24:34 +0000 (10:24 +0000)
committerceriel <none@none>
Fri, 4 Nov 1988 10:24:34 +0000 (10:24 +0000)
lang/m2/comp/Version.c
lang/m2/comp/walk.c

index 12662b6..6bebc5a 100644 (file)
@@ -1 +1 @@
-static char Version[] = "ACK Modula-2 compiler Version 0.40";
+static char Version[] = "ACK Modula-2 compiler Version 0.41";
index 97e4349..472a849 100644 (file)
@@ -544,23 +544,22 @@ WalkStat(nd, exit_label)
                        if (good_forvar) {
                                bstp = BaseType(nd->nd_type);
                                uns = bstp->tp_fund != T_INTEGER;
-                               C_dup(int_size);
-                               CodeDStore(nd);
                                CodePExpr(fnd);
                                C_stl(tmp);
+                               CodePExpr(left->nd_left);
+                               C_dup(int_size);
+                               CodeDStore(nd);
                                C_lol(tmp);
                                if (uns) C_cmu(int_size);
                                else C_cmi(int_size);
+                               C_zgt(l2);
+                               C_lol(tmp);
+                               ForLoopVarExpr(nd);
                                if (left->nd_INT >= 0) {
-                                       C_zgt(l2);
-                                       C_lol(tmp);
-                                       ForLoopVarExpr(nd);
                                }
                                else {
                                        stepsize = -stepsize;
-                                       C_zlt(l2);
-                                       ForLoopVarExpr(nd);
-                                       C_lol(tmp);
+                                       C_exg(int_size);
                                }
                                C_sbu(int_size);
                                if (stepsize) {
@@ -797,7 +796,6 @@ node_warning(nd, W_OLDFASHIONED, "compatibility required in FOR statement");
                return 1;
        }
 
-       CodePExpr(left->nd_left);
        return 1;
 }