Type Classes and Constraint Handling Rules
Kevin Glynn, Martin Sulzmann, Peter J. Stuckey
Abstract
Type classes are an elegant extension to traditional, Hindley-Milner based typing systems. They are used in modern, typed languages such as Haskell to support controlled overloading of symbols. Haskell 98 supports only single-parameter and constructor type classes. Other extensions such as multi-parameter type classes are highly desired but are still not officially supported by Haskell. Subtle issues arise with extensions, which may lead to a loss of feasible type inference or ambiguous programs. A proper logical basis for type class systems seems to be missing. Such a basis would allow extensions to be characterised and studied rigorously. We propose to employ Constraint Handling Rules as a tool to study and develop type class systems in a uniform way.
Create a lesson
Related papers
A Simplified Layout Algebra for GPU Kernels
Nan An, Xiaotian Zhou
Coexponential Exploration in the Clef Programming Language
Houston Haynes
Bayes Rule for Conditioning Probabilistic Programs
Feras A. Saad
Modular Responsiveness Verification of Rust Async Runtimes
Yanze Li, Ivan Beschastnikh, Alexander J. Summers
When Double Rounding is Correct
Brett Saiki, Bill Zorn, Cynthia Richey et al.
Automatically Detecting and Fixing Deadlocks in Go Code with GoDDaR
Gustavo Feio, Jorge Coelho, Miguel Flor et al.