Explorar o código

* fixed (harmless) range error

git-svn-id: trunk@7511 -
Jonas Maebe %!s(int64=18) %!d(string=hai) anos
pai
achega
628ddfa160
Modificáronse 1 ficheiros con 2 adicións e 1 borrados
  1. 2 1
      compiler/ncgcon.pas

+ 2 - 1
compiler/ncgcon.pas

@@ -525,7 +525,8 @@ implementation
                { not plongint, because that will "sign extend" the set on 64 bit platforms }
                { if changed to "paword", please also modify "32-resultdef.size*8" and      }
                { cross-endian code below                                                   }
-               location.value:=pCardinal(value_set)^
+               { Extra aint type cast to avoid range errors                                }
+               location.value:=aint(pCardinal(value_set)^)
 {$else}
                location.value:=reverse_byte(Psetbytes(value_set)^[0]);
                location.value:=location.value or (reverse_byte(Psetbytes(value_set)^[1]) shl 8);