Proceedings of the 14th ACM SIGPLAN International Conference on Functional Programming 2009
DOI: 10.1145/1596550.1596577
|View full text |Cite
|
Sign up to set email alerts
|

Free theorems involving type constructor classes

Abstract: Free theorems are a charm, allowing the derivation of useful statements about programs from their (polymorphic) types alone. We show how to reap such theorems not only from polymorphism over ordinary types, but also from polymorphism over type constructors restricted by class constraints. Our prime application area is that of monads, which form the probably most popular type constructor class of Haskell. To demonstrate the broader scope, we also deal with a transparent way of introducing difference lists into … Show more

Help me understand this report

Search citation statements

Order By: Relevance

Paper Sections

Select...
2
1
1
1

Citation Types

0
5
0

Year Published

2010
2010
2020
2020

Publication Types

Select...
4
3
2

Relationship

2
7

Authors

Journals

citations
Cited by 19 publications
(5 citation statements)
references
References 25 publications
0
5
0
Order By: Relevance
“…The naturality law specifies that malias is a natural transformation. Although we do not give a formal proof, we argue that the law follows from the parametricity of the malias type signature and can be obtained using the method described by Voigtländer [25].…”
Section: The Meaning Of Malias Lawsmentioning
confidence: 89%
“…The naturality law specifies that malias is a natural transformation. Although we do not give a formal proof, we argue that the law follows from the parametricity of the malias type signature and can be obtained using the method described by Voigtländer [25].…”
Section: The Meaning Of Malias Lawsmentioning
confidence: 89%
“…• We believe that for a large range of datatypes T (including all regular datatypes), the naturality properties of traverse (but not 'naturality' in the datatype) actually hold for all polymorphic functions of type Applicative m ⇒ (a → m b) → T a → m (T b); they should be free theorems (Wadler 1989;Voigtländer 2009). …”
Section: Discussionmentioning
confidence: 99%
“…• We believe that for a large range of datatypes T (including all regular datatypes), the naturality properties of traverse (but not 'naturality' in the datatype) actually hold for all polymorphic functions of type Applicative m ⇒ (a → m b) → T a → m (T b); they should be free theorems (Wadler 1989;Voigtländer 2009). • We conjecture the maybe somewhat surprising fact that, in Set, the monadic variant of traverse's type is no more accommodating than the idiomatic one.…”
Section: Discussionmentioning
confidence: 99%