[fpc-pascal] header translation question, 64 bit problem

Jonas Maebe jonas.maebe at elis.ugent.be
Sun Jun 17 13:04:52 CEST 2012


On 17 Jun 2012, at 12:36, Bernd wrote:

> I did not know this.  I have read in many different places that one
> should use packed

Those places please probably said "you should use packed *if you want the layout of a record to be the same on all platforms and across different FPC versions*". In this particular case, you want everything but it to be the same on all platforms. Instead, you want it to change to adapt to the ABI of the different platforms.

And when using {$packrecords c}, the record layout will not change across FPC versions either (unless a bug is found in the alignment rules for that platform, but in that case the change will improve the compatibility with the C record declaration).


Jonas


More information about the fpc-pascal mailing list