Changes between Version 3 and Version 4 of Ticket #14331, comment 31


Ignore:
Timestamp:
Oct 19, 2017 7:59:53 PM (2 years ago)
Author:
goldfire
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #14331, comment 31

    v3 v4  
    1313   b. Instantiate `ki` with fresh unification variables for any kind variables in `ki`. (This is vanilla instantiation for an applied type.)
    1414   b. Unify `ki` with `kappa -> Constraint`, getting a substitution for `kappa`; let the result of this substitution be `ki2`. (Issue an error if unification fails.)
    15    c. It is required that `ki2` have the form `... -> Type` or `kappa2` for some variable `kappa2`. If `ki2` is `kappa2`, then choose `kappa2 := Type`. Now, we have something of the form `... -> Type`. Let the number of arguments in the `...` be `n`.
     15   c. It is required that `ki2` have the form `... -> Type` or `kappa2` for some unification variable `kappa2`. If `ki2` is `kappa2`, then choose `kappa2 := Type`. Now, we have something of the form `... -> Type`. Let the number of arguments in the `...` be `n`.
    1616   d. Let the set of variables mentioned in the `deriving` clause but not locally scoped (that is, they are also mentioned in the `data` declaration head) be `as`.
    1717   e. It is an error if any variable in `as` is mentioned in any of the last `n` arguments in the `data` declaration head. Data family instances need [http://git.haskell.org/ghc.git/blob/7ac22b73b38b60bc26ad2508f57732aa17532a80:/compiler/typecheck/TcDeriv.hs#l747 even more checks].