[Haskell-cafe] Type classes, collections, sum types, closures, and a massive headache

Taylor Hedberg t at tmh.cc
Tue Jan 29 03:17:12 CET 2013


If I understand your message well enough, I think you are looking for
GHC's `ExistentialQuantification` extension. Building heterogeneous
collections is a common example of what existential types are useful
for. Take a look at this wiki page [1]; there is an example of how to
accomplish this there, along with a handful of other techniques.


[1] http://www.haskell.org/haskellwiki/Heterogenous_collections#Existential_types
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://www.haskell.org/pipermail/haskell-cafe/attachments/20130128/c0529bf6/attachment.pgp>


More information about the Haskell-Cafe mailing list