On 11-Nov-1998, David Feuer <[EMAIL PROTECTED]> wrote:
> I think it would be
> really nice if it were possible to create a container capable of
> containing any number of objects of any number of types....
There's a couple of ways of doing this. One way is to use dynamic
typing. The dynamic typing support in ghc-4.00 allows this.
A better way is to use existential typing; I believe several recent
Haskell implementations support that too.
> It would
> avoid the nastiness of a special definition for each tuple type and and
> lead to more flexibility.
I want each tuple arity to be a different type, so that I get a compile
error rather than a run-time error if say I pass a 3-tuple to a
function expecting a 4-tuple.
--
Fergus Henderson <[EMAIL PROTECTED]> | "Binaries may die
WWW: <http://www.cs.mu.oz.au/~fjh> | but source code lives forever"
PGP: finger [EMAIL PROTECTED] | -- leaked Microsoft memo.