Personal tools

Extensible record

From HaskellWiki

(Difference between revisions)
Jump to: navigation, search
(Papers and libraries)
m (Papers and libraries: Updated link to HList paper)
 
Line 5: Line 5:
 
== Papers and libraries ==
 
== Papers and libraries ==
 
* [[CTRex]] Extensible records as a library using closed type families and type literals.
 
* [[CTRex]] Extensible records as a library using closed type families and type literals.
* [http://homepages.cwi.nl/~ralf/HList/ HList – a Haskell library for strongly typed heterogeneous collections] includes also extensible records. Its relatedness to database programming is described in the articles, see also its [http://hackage.haskell.org/trac/summer-of-code/ticket/33 possible] relatedness to [[Libraries and tools/Database interfaces/HaskellDB|HaskellDB]] project.
+
* [http://www.researchgate.net/publication/234806693_Strongly_typed_heterogeneous_collections/file/72e7e51e92fd6109e3.pdf HList – a Haskell library for strongly typed heterogeneous collections] includes also extensible records. Its relatedness to database programming is described in the articles, see also its [http://hackage.haskell.org/trac/summer-of-code/ticket/33 possible] relatedness to [[Libraries and tools/Database interfaces/HaskellDB|HaskellDB]] project.
 
* Daan Leijen: [http://www.cs.uu.nl/~daan/pubs.html#fclabels First-class labels for extensible rows]. See also the description of the Haskell-like language [http://www.cs.uu.nl/~daan/morrow/ Morrow], it is based on the concepts of the article. And [http://www.cs.uu.nl/~daan/pubs.html#scopedlabels Extensible records with scoped labels]: "We describe a natural approach to typing polymorphic and extensible records that is simple, easy to use in practice, and straightforward to implement."
 
* Daan Leijen: [http://www.cs.uu.nl/~daan/pubs.html#fclabels First-class labels for extensible rows]. See also the description of the Haskell-like language [http://www.cs.uu.nl/~daan/morrow/ Morrow], it is based on the concepts of the article. And [http://www.cs.uu.nl/~daan/pubs.html#scopedlabels Extensible records with scoped labels]: "We describe a natural approach to typing polymorphic and extensible records that is simple, easy to use in practice, and straightforward to implement."
 
* Simon Peyton Jones and Greg Morrisett: [http://research.microsoft.com/~simonpj/Haskell/records.html A proposal for records in Haskell]
 
* Simon Peyton Jones and Greg Morrisett: [http://research.microsoft.com/~simonpj/Haskell/records.html A proposal for records in Haskell]

Latest revision as of 23:52, 7 August 2014

Contents


Proposals, implementations can be found on the FirstClassLabels page of Haskell' Wiki.

[edit] 1 Papers and libraries

[edit] 1.1 Libraries on hackage

[edit] 2 Applications

[edit] 2.1 Declarative database management

Such systems can achieve more type safety (compared to direct SQL handling). They usually formulate a relational algebra concept in a declarative language.

[edit] 2.1.1 HaskellDB

A problem where some concepts of extensible records could be useful is described in the HaskellDB project. More precisely, the problem is described in the paper downloadable from

HaskellDB uses its own extensible record system, but see also HaskellDB#Future.

[edit] 2.1.2 CoddFish

CoddFish is another declarative, type safe database system. As for extensible record system, it uses HList --- a Haskell library for strongly typed heterogeneous collections.

[edit] 2.2 Functional Reactive Programming

FRP often makes it necessary to deal with very large tuples as arrow inputs and outputs. For example, a GUI component would receive the behavior of all its writeable properties as its input. Extensible records can therefore make FRP more usable, especially if they provide defaulting.

[edit] 2.2.1 Grapefruit

Grapefruit uses extensible records which support pattern matching and defaulting for functional reactive GUI programming.

[edit] 3 Related concepts

Dependent type -- as an explanation for its relatedness here, see Why Dependent Types Matter written by Thorsten Altenkirch, Conor McBride, James McKinna -- or see at least its Conclusions section (section 8, pages 18--19).

Type arithmetic seems to me also a way yielding some tastes from dependent type theory.

Relational algebra implementations usually use extensible records.