Преглед изворни кода

* give an internalerror if a typed const builder is finalised while there
is still an unfinished aggregate

git-svn-id: trunk@31254 -

Jonas Maebe пре 10 година
родитељ
комит
c946a85ae6
1 измењених фајлова са 5 додато и 0 уклоњено
  1. 5 0
      compiler/aasmcnst.pas

+ 5 - 0
compiler/aasmcnst.pas

@@ -814,6 +814,11 @@ implementation
      var
        prelist: tasmlist;
      begin
+       { have we finished all aggregates? }
+       if (getcurragginfo<>nil) and
+          { in case of syntax errors, the aggregate may not have been finished }
+          (ErrorCount=0) then
+         internalerror(2015072301);
        prelist:=tasmlist.create;
        { only now add items based on the symbolname, because it may be
          modified by the "section" specifier in case of a typed constant }