Sfoglia il codice sorgente

* set pi_uses_exceptions flag only if the try...finally frame is not an implicit frame

git-svn-id: trunk@26731 -
florian 11 anni fa
parent
commit
e5aa0e4316
1 ha cambiato i file con 7 aggiunte e 1 eliminazioni
  1. 7 1
      compiler/nflw.pas

+ 7 - 1
compiler/nflw.pas

@@ -2130,7 +2130,13 @@ implementation
           firstpass(t1);
 
         include(current_procinfo.flags,pi_do_call);
-        include(current_procinfo.flags,pi_uses_exceptions);
+
+        { pi_uses_exceptions is an information for the optimizer and it
+          is only interested in exceptions if they appear inside the body,
+          so ignore implicit frames when setting the flag }
+        if not(implicitframe) then
+          include(current_procinfo.flags,pi_uses_exceptions);
+
         inc(current_procinfo.estimatedtempsize,get_jumpbuf_size);
       end;