On 14 Nov 2006, at 23:12, Daniël Mantione wrote:
Op Tue, 14 Nov 2006, schreef Jonas Maebe:
On 14 Nov 2006, at 22:04, Den Jean wrote:
so that binary compatibility with frequently used
bitmasks in C APIs is easier
Aren't bitpacked records/arrays more appropriate for that?
Semantically speaking, no.
Sorry, I misread "bitmasks" as "bitfields". But using sets for C
bitmasks is very dangerous, since sets are opaque and can differ from
platform to platform (in practice only for endianess currently). It's
the same for bitpacked arrays, in fact. Only bitfields in bitpacked
records are identical as in C if combined with {$packrecords C}
Jonas_______________________________________________
fpc-pascal maillist - fpc-pascal@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-pascal