Re: [Haskell-cafe] Duplicate instance declaration

2007-03-23 Thread Bas van Dijk
On 3/22/07, Twan van Laarhoven <[EMAIL PROTECTED]> wrote: ... An alternative idea would be to use data types instead of classes for the registers and memory locations ... A very nice solution. Thanks very much! Bas van Dijk ___ Haskell-Cafe mailing l

Re: [Haskell-cafe] Duplicate instance declaration

2007-03-22 Thread Twan van Laarhoven
Bas van Dijk wrote: I would also like to get the formatting constraints working. However the solution in the code below gives a "Duplicate instance declarations" error. If I -fallow-overlapping-instances than the type checker goes into an infinite loop. I would like to know why this is ha

[Haskell-cafe] Duplicate instance declaration

2007-03-22 Thread Bas van Dijk
Hello, I'm making an assembly language DSEL in Haskell (just for fun) very similar to the one from Russel O' Conner in [1] I'm trying to specify a 'mov' instruction. A 'mov' instruction has two operands: a destination and a source. There are various constraints on the operands. They have to be o