[fpc-devel] Abs(Variant) unexpected result

Jonas Maebe jonas at freepascal.org
Sun Feb 25 16:04:24 CET 2018

On 25/02/18 15:59, Bart wrote:
> I don't know how Delphi behaves, but the official Delphi docs state
> that Abs() only has overloads for floats, integer and int64.
> If their compiler behaves as the docs say, Abs(Variant) would be a syntax error.

No, because variant can be implicitly converted to all of those types 
and there are different (undocumented by Embarcadero) overload selection 
priorities for each of those types.


More information about the fpc-devel mailing list