[Haskell-cafe] Re: Getting my feet wet - small browser game

Donald Bruce Stewart dons at cse.unsw.edu.au
Wed Dec 20 03:22:32 EST 2006

> Marc A. Ziegert schrieb:
> >software upgrades:
> >use Read/Show classes instead of Foreign.Marshal,
> I'm having second thoughts here.
> Wouldn't Show evaluate all thunks of the data Shown?
> That would mean I couldn't use infinite data structures in data that 
> goes out to disk.

Btw, if you're dumping large structures to disk, using Read/Show is a
bad idea :)

Use NewBinary, at a minimum, or one of the other serialisation modules
(possibly the one used in HAppS based on bytestrings) would be a better

Read/Show is good for testing that the serialising code works, though.

-- Don

More information about the Haskell-Cafe mailing list