
1 Mar
2009
1 Mar
'09
3:12 p.m.
On Sun, Mar 1, 2009 at 6:42 PM, Martin Huschenbett
Hi,
you could do something like
instance (Show a,Read a) => Binary a where put = put . show get = fmap read get
But then you will need the following language extensions: FlexibleInstances, OverlappingInstances, UndecidableInstances
Well, isn't there a good chance it'll end up picking that instance even when a more specific one is available, then? I think the problem here is that I don't know of any way to inform GHC that any particular instance is "less specific".