Sfoglia il codice sorgente

* qword(-int64) can cause an overflow error in case of low(int64). Harmless, so
disable overflow checking around it.

git-svn-id: trunk@8124 -

daniel 18 anni fa
parent
commit
6065bee1c2
1 ha cambiato i file con 4 aggiunte e 0 eliminazioni
  1. 4 0
      compiler/constexp.pas

+ 4 - 0
compiler/constexp.pas

@@ -342,12 +342,16 @@ begin
   result.overflow:=false;
   result.overflow:=false;
   sa:=a.signed and (a.svalue<0);
   sa:=a.signed and (a.svalue<0);
   if sa then
   if sa then
+    {$Q-}
     aa:=qword(-a.svalue)
     aa:=qword(-a.svalue)
+    {$ifdef ena_q}{$Q+}{$endif}
   else
   else
     aa:=a.uvalue;
     aa:=a.uvalue;
   sb:=b.signed and (b.svalue<0);
   sb:=b.signed and (b.svalue<0);
   if sb then
   if sb then
+    {$Q-}
     bb:=qword(-b.svalue)
     bb:=qword(-b.svalue)
+    {$ifdef ena_q}{$Q+}{$endif}
   else
   else
     bb:=b.uvalue;
     bb:=b.uvalue;