[fpc-devel]IntToHex difference

David Butler david at e.co.za
Fri Nov 7 13:36:47 CET 2003


A small difference between FreePascal and Delphi's IntToHex function:

FreePascal's IntToHex function interprets the Digits parameter as the
'maximum number of digits'. Delphi interprets it as the 'minimum
number of digits'.

For example, FreePascal IntToHex($10, 1) = '0', whereas Delphi returns
'10'. IntToHex($10, 3) = '010' on both compilers.


More information about the fpc-devel mailing list