[fpc-pascal] range check error while evaluating constant (number literals larger than$7fffffffffffffff)
Jonas Maebe
jonas.maebe at elis.ugent.be
Tue Dec 6 00:56:58 CET 2011
On 06 Dec 2011, at 00:39, Bernd wrote:
> var
> x : QWord;
>
> begin
> x := $ffffffffffffffff;
> writeln(IntToHex(x, 16));
> end.
All constants > $ffffffff are always parsed as int64. You have to explicitly typecast them to qword() if you want the compiler to treat them that way.
Jonas
More information about the fpc-pascal
mailing list