
30 Mar
2009
30 Mar
'09
11:42 p.m.
G'day all.
Quoting Lennart Augustsson
I think Data.Unique is horrible and should be banned. It encourages a global variable style of programming that will just bite you in the end.
In the sense that it doesn't give you anything that Monad.Supply or Control.Comonad.Supply doesn't, I agree. However, Data.Unique is a building block for the grubby implementation details of prettier, higher-level data structures (e.g. data structures that use hash consing). It's not supposed to be used at the application level. In that sense, it's no worse than unsafePerformIO. Cheers, Andrew Bromage