Browse Source

Minimalist change to avoid Invalid Typecast error on class when compiled with '-CriotR -O2' for i386-go32v2 target

git-svn-id: trunk@43565 -
pierre 5 năm trước cách đây
mục cha
commit
c882828fd0
1 tập tin đã thay đổi với 2 bổ sung0 xóa
  1. 2 0
      compiler/i386/aoptcpu.pas

+ 2 - 0
compiler/i386/aoptcpu.pas

@@ -94,6 +94,8 @@ unit aoptcpu;
                   p := tai(p.next);
                   Result:=true;
                 end;
+              if not (p is taicpu) then
+                exit;
               case taicpu(p).opcode Of
                 A_IMUL:
                   Result:=PrePeepholeOptIMUL(p);