cvs commit: fptools/ghc/compiler/iface TcIface.lhs

Simon Peyton Jones simonpj at microsoft.com
Wed Jun 14 07:46:15 EDT 2006


simonpj     2006/06/14 04:46:15 PDT

  Modified files:        (Branch: ghc-6-4-branch)
    ghc/compiler/iface   TcIface.lhs 
  Log:
  	Fix a nasty GADT bug
  
  Consider typechecking an interface decl like this:
  
  f (x::T a) (y::a) = case x of
  			C -> case y of ...
  
  Matching on 'x' refines 'y' to a data type.  tcIfaceExpr of IfaceCase
  expects 'y' to have a data type, but if we don't refine the envt it'll
  just have the type 'a'.
  
  Solution: refine the envt, as is done in the simplifier.  Sigh.
  System FC is better!
  
  Revision  Changes    Path
  1.32.2.3  +24 -8     fptools/ghc/compiler/iface/TcIface.lhs


More information about the Cvs-ghc mailing list