Browse Source

* compiler didn't complain about l1+l2:=l1+l2; it gave only an assembler
error, fixed

florian 26 years ago
parent
commit
51b96fabc3
1 changed files with 13 additions and 1 deletions
  1. 13 1
      compiler/cg386ld.pas

+ 13 - 1
compiler/cg386ld.pas

@@ -431,6 +431,14 @@ implementation
                end;
                end;
          end;
          end;
 {$endif dummy}
 {$endif dummy}
+         if not(p^.left^.location.loc in [LOC_REFERENCE,LOC_CFPUREGISTER,
+           LOC_CREGISTER,LOC_MMXREGISTER,LOC_CMMXREGISTER]) then
+           begin
+              CGMessage(cg_e_illegal_expression);
+              exit;
+           end;
+
+
          loc:=p^.left^.location.loc;
          loc:=p^.left^.location.loc;
          { lets try to optimize this (PM)            }
          { lets try to optimize this (PM)            }
          { define a dest_loc that is the location      }
          { define a dest_loc that is the location      }
@@ -989,7 +997,11 @@ implementation
 end.
 end.
 {
 {
   $Log$
   $Log$
-  Revision 1.88  1999-09-27 23:44:47  peter
+  Revision 1.89  1999-10-12 22:35:48  florian
+    * compiler didn't complain about l1+l2:=l1+l2; it gave only an assembler
+      error, fixed
+
+  Revision 1.88  1999/09/27 23:44:47  peter
     * procinfo is now a pointer
     * procinfo is now a pointer
     * support for result setting in sub procedure
     * support for result setting in sub procedure