patch applied (ghc): Equality constraint solver is now externally pure

chak at cse.unsw.edu.au chak at cse.unsw.edu.au
Mon Apr 27 10:40:11 EDT 2009


Mon Apr 27 07:03:16 PDT 2009  Manuel M T Chakravarty <chak at cse.unsw.edu.au>
  * Equality constraint solver is now externally pure
  Ignore-this: bd7c31a7d9e62437e4d83f70b48220af
  - This patch changes the equality constraint solver such that it does not
    instantiate any type variables that occur in the constraints that are to be
    solved (or in the environment).  Instead, it returns a bag of type bindings.
  - If these type bindings (together with the other results of the solver) are
    discarded, solver invocation has no effect (outside the solver) and can be
    repeated (that's imported for TcSimplifyRestricted).
  - For the type bindings to take effect, the caller of the solver needs to 
    execute them. 
  - The solver will still instantiate type variables thet were created during 
    solving (e.g., skolem flexibles used during type flattening).
  
    See also http://hackage.haskell.org/trac/ghc/wiki/TypeFunctionsSolving

    M ./compiler/coreSyn/CoreFVs.lhs -1 +8
    M ./compiler/typecheck/Inst.lhs -18 +49
    M ./compiler/typecheck/TcMType.lhs -8 +28
    M ./compiler/typecheck/TcRnMonad.lhs -2 +44
    M ./compiler/typecheck/TcRnTypes.lhs -6 +23
    M ./compiler/typecheck/TcSimplify.lhs -15 +20
    M ./compiler/typecheck/TcTyFuns.lhs -236 +394
    M ./compiler/typecheck/TcType.lhs -1 +2

View patch online:
http://darcs.haskell.org/ghc/_darcs/patches/20090427140316-6295e-7c43bac8aaf3004c788838659a2c3221b784409c.gz



More information about the Cvs-ghc mailing list