mirrored from https://gitlab.haskell.org/ghc/ghc.git
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix Trac #7939, and add kind inference to closed type families.
Now, all open type families have result kinds that default to *. Top-level type families have all arguments default to *, and associated type families have all arguments that are not mentioned in the class header default to *. Closed type families perform kind inference, but generalize only over those kind variables that are parametric in their use. This is all a little fiddly and specific, but it seems to follow use cases. This commit also includes a large Note [Kind-checking strategies] in TcHsType that helps keep all of this straight.
- Loading branch information
Richard Eisenberg
committed
Jun 28, 2013
1 parent
a7798e9
commit 8c5e734
Showing
4 changed files
with
345 additions
and
112 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.