Henning, The code is not intended to fit into a larger application. I am trying to understand instance-implements-class relation. My experiment consists of writing simple English sentences and then seeing how they could be specified and implemented in Haskell. I am sure that this simple requirement could easily be coded in Haskell, but I studying how to specify the requirement using type classes.
The bottom line is I want to stay with plain vanilla type classes. If there is no simple way to do this using type classes then I am obviously using the wrong technique. Thanks, Pat On 17/01/2011 11:39, Henning Thielemann wrote: > > But I suspect, what you try to do is not what you need. If you tell us > what you want to do, we can certainly give more helpful answers. > > Maybe you want to do something with functional dependencies, such that > 'String' result type is automatically chosen if the argument type is > 'Int'. But before suggesting this type extension, I'd like to know more > about your problem. I am trying to understand instance-implements-class relation. This message has been scanned for content and viruses by the DIT Information Services E-Mail Scanning Service, and is believed to be clean. http://www.dit.ie _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe