skip to main content
10.1145/2502488.2502494acmconferencesArticle/Chapter ViewAbstractPublication PagesicfpConference Proceedingsconference-collections
research-article

Usage of generic programming on hackage: experience report

Published: 28 September 2013 Publication History

Abstract

Generic programming language constructs, tools and libraries have been available in Haskell since the first report on the programming language Haskell. At the beginning of the 1990s generic programming techniques could be used via the deriving construct, and since then numerous generic programming libraries and tools have been developed. At the time of writing, the categories `generic' and 'generics' on Hackage, the online repository of Haskell software, contain 53 packages. Although not all of these are generic programming libraries or tools, there are many approaches to generic programming to choose from. This brief paper discusses an analysis of the usage of generic programming language constructs, tools, and libraries. We analyse how often which language constructs, tools, and libraries are used on Hackage, how often class instances are derived generically or written manually, and for some libraries, how often the functions that appear in these libraries are used.

References

[1]
J. Cheney and R. Hinze. A lightweight implementation of generics and dynamics. In Haskell'02, pages 90--104, 2002.
[2]
D. Coutts. Solving the diamond dependency problem. http://www.well-typed.com/blog/12, 2008.
[3]
R. Hinze. Generics for the masses. In ICFP'04, pages 236--243, 2004.
[4]
R. Hinze and J. Jeuring. Generic haskell: Applications. In Generic Programming, volume 2793 of LNCS, pages 57--96, 2003.
[5]
R. Hinze and S. Peyton Jones. Derivable type classes. In Proceedings of the Fourth Haskell Workshop, 2000.
[6]
R. Hinze, J. Jeuring, and A. Löh. Comparing approaches to generic programming in haskell. In Summer School on Datatype-generic programming, LNCS, pages 72--149, 2007.
[7]
P. Hudak, S. Peyton Jones, P. Wadler, B. Boutel, J. Fairbairn, J. Fasel, M. M. Guzmán, K. Hammond, J. Hughes, T. Johnsson, D. Kieburtz, R. Nikhil, W. Partain, and J. Peterson. Report on the programming language haskell: a non-strict, purely functional language version 1.2. SIGPLAN Notices, 27 (5): 1--164, 1992.
[8]
P. Jansson and J. Jeuring. PolyP -- a polytypic programming language extension. In POPL'97, pages 470--482, 1997.
[9]
J. Jeuring, S. Leather, J. P. Magalhães, and A. R. Yakushev. Libraries for generic programming in Haskell. In Advanced Functional Programming, volume 5832 of LNCS, pages 165--229, 2008.
[10]
J. Jeuring, J. P. Magalhães, and B. Heeren. Generic programming for domain reasoners. In TFP '09, pages 113--128, 2009.
[11]
I. Jones, S. Peyton Jones, S. Marlow, M. Wallace, and R. Patterson. The Haskell Cabal, a common architecture for building applications and libraries, 2005.
[12]
O. Kiselyov. Smash your boilerplate without class and Typeable. http://article.gmane.org/gmane.comp.lang.haskell.general/14086, 2006.
[13]
R. Lämmel and S. Peyton Jones. Scrap your boilerplate: a practical design pattern for generic programming. In ICFP '03, 2003.
[14]
A. Löh, J. Jeuring, T. van Noort, A. Rodriguez, D. Clarke, R. Hinze, and J. de Wit. The Generic Haskell user's guide, Version 1.80 - Emerald release. Technical Report UU-CS-2008-011, Utrecht University, 2008.
[15]
J. P. Magalhães and W. B. de Haas. Functional modelling of musical harmony: an experience report. In ICFP '11, pages 156--162, 2011.
[16]
J. P. Magalhães, A. Dijkstra, J. Jeuring, and A. Löh. A generic deriving mechanism for Haskell. Haskell '10, pages 37--48, 2010.
[17]
N. Mitchell. Deriving a relationship from a single example. In AAIP '10, volume 5812 of LNCS, 2010.
[18]
N. Mitchell and C. Runciman. Uniform boilerplate and list processing. In Haskell '07, pages 49--60, 2007.
[19]
J. G. Morris. Experience report: using Hackage to inform language design. In Haskell '10, pages 61--66, 2010.
[20]
U. Norell and P. Jansson. Prototyping generic programming in template haskell. In MPC '04, volume 3125 of LNCS, pages 314--333, 2004.
[21]
S. Peyton Jones. Haskell 98 Language and Libraries: The Revised Report. Cambridge University Press, 2003.
[22]
A. Rodriguez, J. Jeuring, P. Jansson, A. Gerdes, O. Kiselyov, and B. C. d. S. Oliveira. Comparing libraries for generic programming in Haskell. In Haskell '08, pages 111--122, 2008.
[23]
S. Weirich. RepLib: a library for derivable type classes. In Haskell '06, pages 1--12, 2006.
[24]
N. Winstanley and J. Meacham. DrIFT user guide, 2006. http://repetae.net/ john/computer/haskell/DrIFT/.

Cited By

View all
  • (2022)Evolution of a haskell repository and its use of monadsProceedings of the 37th ACM/SIGAPP Symposium on Applied Computing10.1145/3477314.3506982(1475-1482)Online publication date: 25-Apr-2022
  • (2021)Which monads Haskell developers use: An exploratory studyScience of Computer Programming10.1016/j.scico.2020.102523201(102523)Online publication date: Jan-2021
  • (2020)String Representations of Java Objects: An Empirical StudySOFSEM 2020: Theory and Practice of Computer Science10.1007/978-3-030-38919-2_39(479-490)Online publication date: 20-Jan-2020
  • Show More Cited By

Recommendations

Comments

Information & Contributors

Information

Published In

cover image ACM Conferences
WGP '13: Proceedings of the 9th ACM SIGPLAN workshop on Generic programming
September 2013
92 pages
ISBN:9781450323895
DOI:10.1145/2502488
Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than the author(s) must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected].

Sponsors

Publisher

Association for Computing Machinery

New York, NY, United States

Publication History

Published: 28 September 2013

Permissions

Request permissions for this article.

Check for updates

Author Tags

  1. deriving mechanism
  2. generic programming
  3. hackage
  4. haskell

Qualifiers

  • Research-article

Conference

ICFP'13
Sponsor:

Acceptance Rates

WGP '13 Paper Acceptance Rate 8 of 14 submissions, 57%;
Overall Acceptance Rate 30 of 43 submissions, 70%

Upcoming Conference

ICFP '25
ACM SIGPLAN International Conference on Functional Programming
October 12 - 18, 2025
Singapore , Singapore

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • Downloads (Last 12 months)3
  • Downloads (Last 6 weeks)0
Reflects downloads up to 03 Mar 2025

Other Metrics

Citations

Cited By

View all
  • (2022)Evolution of a haskell repository and its use of monadsProceedings of the 37th ACM/SIGAPP Symposium on Applied Computing10.1145/3477314.3506982(1475-1482)Online publication date: 25-Apr-2022
  • (2021)Which monads Haskell developers use: An exploratory studyScience of Computer Programming10.1016/j.scico.2020.102523201(102523)Online publication date: Jan-2021
  • (2020)String Representations of Java Objects: An Empirical StudySOFSEM 2020: Theory and Practice of Computer Science10.1007/978-3-030-38919-2_39(479-490)Online publication date: 20-Jan-2020
  • (2017)A preliminary assessment of how monads are used in HaskellProceedings of the 21st Brazilian Symposium on Programming Languages10.1145/3125374.3125385(1-7)Online publication date: 21-Sep-2017

View Options

Login options

View options

PDF

View or Download as a PDF file.

PDF

eReader

View online with eReader.

eReader

Figures

Tables

Media

Share

Share

Share this Publication link

Share on social media