
30 Jan
2006
30 Jan
'06
9:26 p.m.
On Mon, 30 Jan 2006, John Meacham wrote:
an alternative might be to just allow existential types in structures so we can have [exists a . Foo a => a], but that probably has its own can of worms...
Yup. The boxy types paper gives us impredicativity and allows us to define the type, but in GHC you can't allow [exists a . num a => a] to subsume [Int] because that'd require mapping across the list to add in the dictionaries. You can hack it for lists, but you can't do it for general structures. I believe JHC could handle it fine though. -- flippa@flippac.org A problem that's all in your head is still a problem. Brain damage is but one form of mind damage.