Correct-by-Construction Implementation of Typecheckers

Typechecking records with depth and width subtyping

Bachelor Thesis (2024)
Author(s)

K.J. Ciaś (TU Delft - Electrical Engineering, Mathematics and Computer Science)

Contributor(s)

Jesper Cockx – Mentor (TU Delft - Programming Languages)

S. Juhošová – Mentor (TU Delft - Education and Student Affairs)

Thomas Durieux – Graduation committee member (TU Delft - Software Engineering)

Faculty
Electrical Engineering, Mathematics and Computer Science
More Info
expand_more
Publication Year
2024
Language
English
Graduation Date
25-06-2024
Awarding Institution
Delft University of Technology
Project
CSE3000 Research Project
Programme
Computer Science and Engineering
Faculty
Electrical Engineering, Mathematics and Computer Science
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

Typecheckers help avoid bugs in code by catching errors early. Their implementation can, however, be incorrect, leading to inconsistencies in their operation. This research explores how we can use Agda and correct-by-construction programming to create a typechecker guaranteed to be correct in its implementation. For this purpose, I based a toy language on the simply typed lambda calculus extended with records and subtyping. The resulting typechecker is proven to be sound and complete with respect to the typing and subtyping rules of the toy language. This paper compares the correct-by-construction method to existing typecheckers. The new approach offers a greater degree of trust in its implementation but comes at the cost of being more demanding to develop and maintain.

Files

Cbc-typechecker-records.pdf
(pdf | 0.289 Mb)
License info not available