What a great error message:

qcgadt.hs:115:7:
    My brain just exploded.
    I can't handle pattern bindings for existentially-quantified constructors.
    In the binding group
        (Rep x) = uncompressRep s
    In the definition of `uncompressRep':
        uncompressRep (0 : 1 : 0 : s) = let (Rep x) = uncompressRep s in Rep 
(RList x)
Failed, modules loaded: none.

Here's the offending line:

uncompressRep (0:1:1:s) =
   let (Rep x) = uncompressRep s in
      Rep (RList x)

But this works:

uncompressRep (0:1:0:s) =
   let x = uncompressRep s in
       case x of
          (Rep y) -> Rep (RList y)

Can someone explain this?

Thanks, Dominic.



_______________________________________________
Haskell mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/haskell

Reply via email to