Mon Sep 25 05:13:51 PDT 2006  [EMAIL PROTECTED]
  * Fix newtype deriving properly (un-doing Audreys patch)
  
  The newtype-deriving mechanism generates a HsSyn case expression looking
  like this
        case (d `cast` co) of { ... }
  That is, the case expression scrutinises a dictionary.  This is 
  otherwise never seen in HsSyn, and it made the desugarer
  (Check.get_unused_cons) crash in tcTyConAppTyCon.
  
  It would really be better to generate Core in TcInstDecls (the newtype
  deriving part) but I'm not going to do that today.  Instead, I made
  Check.get_unused_cons a bit more robust.
  
  Audrey tried to fix this over the weekend, but her fix was, alas, utterly
  bogus, which caused mysterious failures later.  I completely undid this
  change.
  
  Anyway it should work now!
  

    M ./compiler/deSugar/Check.lhs -6 +6
    M ./compiler/typecheck/TcClassDcl.lhs +2
    M ./compiler/typecheck/TcInstDcls.lhs +3
    M ./compiler/typecheck/TcType.lhs -11 +7
_______________________________________________
Cvs-ghc mailing list
[EMAIL PROTECTED]
http://www.haskell.org/mailman/listinfo/cvs-ghc

Reply via email to