Proving Type Class Laws for Haskell

Andreas Arvidsson, Moa Johansson, Robin Touche
8/17/2018
cs.PL

Official code: chip2n/hipspec-typeclasses (0 stars, Haskell, last commit 2016-06-01).

Abstract

Type classes in Haskell are used to implement ad-hoc polymorphism, i.e. a way to ensure both to the programmer and the compiler that a set of functions are defined for a specific data type. All instances of such type classes are expected to behave in a certain way and satisfy laws associated with the respective class.

Show full abstract

These are however typically just stated in comments and as such, there is no real way to enforce that they hold. In this paper we describe a system which allows the user to write down type class laws which are then automatically instantiated and sent to an inductive theorem prover when declaring a new instance of a type class.

View on arXivView PDF

Code Implementations(1)

Repository for master thesis "Proving Type-Class Laws in Haskell".

00Haskell, ShellNov 19, 201510 years agoNOASSERTION

Similar Papers

Cite this paper

@article{arvidsson2018proving,
  title  = {Proving Type Class Laws for Haskell},
  author = {Andreas Arvidsson and Moa Johansson and Robin Touche},
  year   = {2018},
  eprint = {1808.05789},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/1808.05789}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/1808.05789.svg)](https://codeofpaper.com/paper/1808.05789)

Discussion