Abstract
We present a calculational approach to the design of type checkers, showing how they can be derived from behavioural specifications using equational reasoning. We focus on languages whose semantics can be expressed as a fold, and show how the calculations can be simplified using fold fusion. This approach enables the compositional derivation of correct-by-construction type checkers based on solving and composing fusion preconditions. We introduce our approach using a simple expression language, to which we then add support for exception handling and checked exceptions.
Author supplied keywords
Cite
CITATION STYLE
Garby, Z., Bahr, P., & Hutton, G. (2025). The Calculated Typer (Functional Pearl). In Haskell 2025 - Proceedings of the 18th ACM SIGPLAN International Symposium on Haskell, Co-located with ICFP/SPLASH 2025 (pp. 17–29). Association for Computing Machinery, Inc. https://doi.org/10.1145/3759164.3759346
Register to see more suggestions
Mendeley helps you to discover research relevant for your work.