소스 검색

* explicitly reset successor if noreturn is set

git-svn-id: trunk@49487 -
florian 4 년 전
부모
커밋
a988c0fab1
1개의 변경된 파일3개의 추가작업 그리고 1개의 파일을 삭제
  1. 3 1
      compiler/optutils.pas

+ 3 - 1
compiler/optutils.pas

@@ -307,7 +307,9 @@ unit optutils;
               begin
                 { not sure if this is enough (FK) }
                 result:=p;
-                if not(cnf_call_never_returns in tcallnode(p).callnodeflags) then
+                if cnf_call_never_returns in tcallnode(p).callnodeflags then
+                  p.successor:=nil
+                else
                   p.successor:=succ;
               end;
             inlinen: