[Agda] Are .agdai files portable?

Nils Anders Danielsson nad at Cs.Nott.AC.UK
Mon Apr 12 16:38:11 CEST 2010


On 2010-04-11 23:59, Iain Lane wrote:
> How portable? Are they dependent on architecture / endianness / anything
> else?

We use Data.Binary and Codec.Compression.GZip, which should be
architecture independent. I see that interface files contain Ints and
Doubles, which are not guaranteed to have a certain size or format.
Data.Binary stores Ints using 64 bits on both 32-bit and 64-bit
platforms, but truncates the values when reading on 32-bit platforms. I
have now replaced uses of Int with Int32 (I hope this does not incur a
performance penalty on 64-bit platforms); is there a
platform-independent variant of Double?

--
/NAD


More information about the Agda mailing list