GHC/Type system

From HaskellWiki
Revision as of 16:40, 31 October 2012 by Simonpj (talk | contribs)
Jump to: navigation, search

Type system extensions in GHC

GHC comes with a rather large collection of type-system extensions (beyond Haskell 98). They are all documented in the user manual, but this page is a place to record user-oriented observations, notes, and suggestions on how to use them.

* Indexed data types
* Agda-like "holes" in GHC
* "stand-alone deriving" declarations
* Type signatures and ambiguity
* Overlapping instances.  GHC supports overlapping instances, with carefully specified rules. Make sure you read the relevant sections of the user manual.  Here is an appliation note about advanced use of overlapping instances, combined with functional dependencies.