Dependently Typed Languages in Statix

Conference Paper (2023)
Author(s)

Jonathan Brouwer (Student TU Delft)

Jesper Cockx (TU Delft - Programming Languages)

Aron Zwaan (TU Delft - Programming Languages)

Research Group
Programming Languages
DOI related publication
https://doi.org/10.4230/OASIcs.EVCS.2023.6 Final published version
More Info
expand_more
Publication Year
2023
Language
English
Research Group
Programming Languages
Article number
6
ISBN (electronic)
9783959772679
Event
2023 Eelco Visser Commemorative Symposium, EVCS 2023 (2023-04-05 - 2023-04-05), Delft, Netherlands
Downloads counter
138
Collections
Institutional Repository
Reuse Rights

Other than for strictly personal use, it is not permitted to download, forward or distribute the text or part of it, without the consent of the author(s) and/or copyright holder(s), unless the work is under an open content license such as Creative Commons.

Abstract

Static type systems can greatly enhance the quality of programs, but implementing a type checker that is both expressive and user-friendly is challenging and error-prone. The Statix meta-language (part of the Spoofax language workbench) aims to make this task easier by automatically deriving a type checker from a declarative specification of a type system. However, so far Statix has not been used to implement dependent types, which is a class of type systems which require evaluation of terms during type checking. In this paper, we present an implementation of a simple dependently typed language in Statix, and discuss how to extend it with several common features such as inductive data types, universes, and inference of implicit arguments. While we encountered some challenges in the implementation, our conclusion is that Statix is already usable as a tool for implementing dependent types.