[Haskell-cafe] Transactional container for storing anonymous deletable objects

Marc Weber marco-oweber at gmx.de
Sun Dec 28 21:18:48 EST 2008


Hi John

Sorry, I don't think I really grasp your problem?

I think you're mixing two things:
a) which data type to use to store whatever you like?
  * http://haskell.org/haskellwiki/Existential_type
  * Typable and Data.Dynamic
  etc..
b) Which container to use to put in stuff, return an identifier so that
  it can be removed by id again?
  There are many ways. Probably something like Data.Map or finger trees
  will do very well.. (use Int as key type and use max + 1 when
  inserting a new one or such?)

I hope I've helped you in some way..

Sincerly
Marc Weber


More information about the Haskell-Cafe mailing list