| Simulating quantified class constraints |
| Full text |
Pdf
(125 KB)
|
| Source
|
Haskell Workshop
archive
Proceedings of the 2003 ACM SIGPLAN workshop on Haskell
table of contents
Uppsala, Sweden
Pages: 98 - 102
Year of Publication: 2003
ISBN:1-58113-758-3
|
|
Author
|
|
| Sponsors |
|
| Publisher |
|
| Bibliometrics |
Downloads (6 Weeks): 4, Downloads (12 Months): 24, Citation Count: 1
|
|
|
ABSTRACT
Defining nontrivial class instances for irregular and exponential datatypes in Haskell is challenging, and as a solution it has been proposed to extend the language with quantified class constraints of the form ∀a. C a ⇒ C' (f a) in the contexts of instance declarations. We show how to express the equivalent of such constraints in vanilla Haskell 98, but their utility in this language is limited. We also present a more flexible solution, which relies on a widely-supported language extension.
REFERENCES
Note: OCR errors may be found in this Reference List extracted from the full text article. ACM has opted to expose the complete List rather than only correct and linked references.
| |
1
|
|
| |
2
|
J. Y. Girard. Interpretation Fonctionnelle et Elimination des Coupures dans l'Arithmetique d'Ordre Superieur. PhD thesis, University of Paris VII, 1972.
|
| |
3
|
Ralf Hinze. Polytypic values possess polykinded types. Science of Computer Programming, 43:129--159, 2002.
|
| |
4
|
Ralf Hinze and Simon~Peyton Jones. Derivable type classes. In Proceedings of the 2000 ACM SIGPLAN Haskell Workshop, volume 41 of Electronic Notes in Theoretical Computer Science, Montreal, Canada, September 2000. Elsevier. http://www.elsevier.nl/inca/publications/store/5/0/5/6/2/5/.
|
| |
5
|
Simon Peyton Jones. Re: Rank-2 polymorphism & type inference, December 2000. Message posted on the Haskell mailing list, available at http://haskell.cs.yale.edu/pipermail/haskell/ 2000-December/006303.html.
|
| |
6
|
Simon Peyton Jones. Deriving excitement, February 2002. Message posted on the Haskell mailing list, available at http://haskell.cs.yale.edu/pipermail/haskell/2002-February/005426.html.
|
| |
7
|
Conor T. McBride. Re: higher-kind deriving... or not, February 2002. Message posted on the Haskell-café mailing list, available at http://www.haskell.org/ pipermail/haskell-cafe/2002-February/002785.html.
|
 |
8
|
|
 |
9
|
|
| |
10
|
Ashley Yakeley. Re: Arrow classes, July 2003. Message posted on the Haskell-café mailing list, available at http://haskell.cs.yale.edu/pipermail/ haskell-cafe/2003-July/004659.html.
|
|