On Fri, 22 Oct 2021 08:42:57 +0200, LacaK via fpc-devel 
<[email protected]> wrote:
> Hi ,
> what data type is result of multiplication of: (Currency * Double) on 
> Win64 (and on Win32)?
>    c:=1115;
>    d:=100000000;
>    writeln(Round(c*d)); // gives -72967440737

        32 bit version gives always 111500000000 as a result (and
floating point math should always have extended precision intermeiate
there) . But even with double intermediate result on 64 bit versions 
there should not be any problems. 1.1150000000000000E+011 is well in 
range of that type.


-- 
Virgo Pärna 
[email protected]

_______________________________________________
fpc-devel maillist  -  [email protected]
https://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-devel

Reply via email to