On 13 jun 2007, at 11:34, josepascual wrote:
else Result :=Round(VarAsType(dataNum, varDouble))//varInteger)
.
.
.
compile okey in 2.1.1 and 2.1.4 fpc for i386 but 2.1.1 and 2.1.4
ppccrossarm
this is the error:
===
.
.
(431,58) Error: Can't determine which overloaded function to call
.
.
===
error is talking about Round.
That is because the overload priority for routines which accept a 64
bit integer (int64/qword, currency, and also comp on non-x86) and a
64 bit float(double) is the same when passing a variable variant
argument. Since we have round(comp), round(currency) and round
(double), the compiler cannot choose which one you want if you pass a
variant. The reason it compiles on i386, is that you also have a round
(extended) there, which has a higher priority than the 64 bit variants.
So you need to fix your code by adding an extra VarAsType(...,double)
call.
Jonas
_______________________________________________
fpc-pascal maillist - fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal