1994
DOI: 10.1007/3-540-57880-3_16
|View full text |Cite
|
Sign up to set email alerts
|

Type classes in Haskell

Abstract: This paper defines a set of type inference rules for resolving overloading introduced by type classes. Programs including type classes are transformed into ones which may be typed by the HindleyMilner inference rules. In contrast to other work on type classes, the rules presented here relate directly to user programs. An innovative aspect of this work is the use of second-order lambda calculus to record type information in the program.

Help me understand this report

Search citation statements

Order By: Relevance

Paper Sections

Select...
2
1
1
1

Citation Types

0
37
0

Year Published

1999
1999
2011
2011

Publication Types

Select...
4
4

Relationship

1
7

Authors

Journals

citations
Cited by 36 publications
(37 citation statements)
references
References 9 publications
0
37
0
Order By: Relevance
“…-The target language is C++ instead of ML [58] or System F [59]. This impacts the translation because C++ has neither parametric polymorphism nor closures, both of which are used extensively in the translations for Haskell.…”
Section: An Implementation Of Gmentioning
confidence: 99%
See 1 more Smart Citation
“…-The target language is C++ instead of ML [58] or System F [59]. This impacts the translation because C++ has neither parametric polymorphism nor closures, both of which are used extensively in the translations for Haskell.…”
Section: An Implementation Of Gmentioning
confidence: 99%
“…The goal of the prototype is not to produce high performance executables but instead to demonstrate the implementability of G and provide an executable semantics. The basic idea of the translation comes from Haskell type classes [58,59]. The constraints on generic functions are translated into extra function parameters.…”
Section: An Implementation Of Gmentioning
confidence: 99%
“…• type classes [15]: Type classes are Haskell's major innovation for supporting ad-hoc polymorphism. A type class declaration corresponds to the type-signature of an overloaded value -or rather, to a collection of type signatures.…”
Section: Related Workmentioning
confidence: 99%
“…For this purpose, we make use of the type class resolution mechanism [11] to instrument programs with run-time checks. The idea is that whenever we come across a program part which gives rise to an unresolved constraint, we replace this program part with an error statement (i.e.…”
Section: Mixing Static and Dynamic Verificationmentioning
confidence: 99%
“…We conclude in Section 5 where we also discuss related work. We assume some familiarity with type classes [38,11]. Throughout the paper, we will use Haskell-style syntax in examples.…”
Section: Introductionmentioning
confidence: 99%